Liquid Glass Effects for Your Web

An open-source and a lightweight JavaScript library inspired by modern liquid glass effect. Transform your UI elements into sleek, frosted liquid glass components instantly.

GlassiFy

Lightweight

Optimized for performance with minimal impact on load times.

Real-time Effects

Dynamic backdrop filters that react to the content behind them.

Customizable

Two liquid glass effects to choose from. Customize them to fit your design.


Interactive Playground

Drag the elements to see the liquid glass effect in action. (Demo)

GLASSIFY

Glass Card

Drag me over the background to see the liquid glass effect.


GlassiFy Documentation

Comprehensive guide to implementing GlassiFy Liquid Glass Effects on your website.

GlassiFy {version}

{release-date}


Changelog: View here

Step 1 - Include the Library

Add the script tag to your HTML file. You can use the official CDN or your self-hosted version.

Option A: Official CDN
<script src="https://glassify.saviru.me/cdn/{version}/glassify.js"></script>
Option B: Self-Hosted
<script src="path/to/glassify.js"></script>

Download Here!

Step 2 - Initialize Library

Use the glassi-fy custom element in the body of your HTML to apply the liquid glass effect.

Default Mode
<glassi-fy></glassi-fy>
Super Mode
<glassi-fy mode="super"></glassi-fy>

Configuration Attributes

You can customize the effect using attributes inside the opening tag. Do not add content between the tags.

Attribute Default Range Description Mode
frequency 0.01 0 - 1 Controls the turbulence frequency. Super Only *
octaves 3 2 - 8 Level of detail in the noise. Super Only *
scale 45 25 - 75 Displacement scale magnitude. Any
blur 3 2 - 10 Blur radius for background elements. Any
brightness 1.4 1 - 2 Backdrop brightness intensity. Any
Example Configuration:
<glassi-fy scale="50" blur="5" ></glassi-fy>

Step 3 - Add Class

Apply the .glassify class to any HTML element you want to have the liquid-glass effect.

<div class="mydiv glassify">
  Your Element
</div>

Step 4 - Custom Styling

You can further customize the appearance using standard CSS. You should define dimensions and basic background colors.

.mydiv {
  width: 300px;
  height: 300px;
  background-color: rgba(11, 75, 203, 0.4);
  color: white;
}