Instructions

SVG icon use

Uploading SVG files

This method is simpler for static icons that do not require extensive customization or dynamic styling.

  • Prepare SVG file: Ensure your SVG file is ready for use.
  • Add an image element: In Webflow, add an "Image" element to your design.
  • Upload SVG: Upload your SVG file to the Image element, similar to how you would upload any other image file.
  • Styling: You can then adjust the size and position of the SVG using Webflow's standard styling options for image elements.
  • SVG element color: Open the SVG from Assets in a text editor, replace the HEX color with your chosen color, save, and overwrite the original file.

Customizing colors

To change a color

This template uses Webflow’s Variables feature, allowing you to update colors across the entire site with ease.

  • Open the Variables panel.
  • Select the color variable you want to edit.
  • Adjust the value - your changes will automatically update throughout the site.

Changing fonts

To update fonts

To adjust the font family, open the Variables panel and select the font family you want to modify.

  • Open the Variables panel.
  • Open Site settings > Fonts and make your changes.
  • After uploading your font in Site settings, go to the Variables panel and choose the new font family.

Template support

We’re happy to help! Reach out via the Webflow Template Support page and we’ll respond soon.

To begin building your site, duplicate the relevant page and start editing or adding sections from other pages.

GSAP guide

Every GSAP script used in this template is listed on this page, along with instructions on how to find and edit each one. Each code block includes clear explanations to help you understand exactly how it works.

The script is located in Site settings under the Footer code area.

Counter on scroll

This script creates a number counter animation that runs when the element scrolls into view. The numbers animate from 0 to their final value using a scrambling number effect powered by GSAP.

<script>
//COUNTER ON SCROLL
document.querySelectorAll('.counter-animation').forEach(el => {
  const finalValue = el.textContent.trim();
 
  gsap.set(el, { textContent: "0" });
  
  ScrollTrigger.create({
    trigger: el,
    start: "top 100%",
    once: true,
    onEnter: () => {
      gsap.to(el, {
        duration: 3,
        scrambleText: {
          text: finalValue,
          chars: "0123456789",
          revealDelay: 0.2
        },
        ease: "power3.out"
      });
    }
  });
});
</script>
Service CMS image hover interaction

This GSAP interaction syncs service links with CMS images, using smooth fade and slide animations on hover, focus, or click. The first item is active by default, with dynamic active states for links, text, and arrows.


window.Webflow = window.Webflow || [];

window.Webflow.push(function () {
  if (typeof gsap === "undefined") {
    console.error("GSAP is not loaded.");
    return;
  }

  // Find the two independent CMS lists
  const serviceLinks = Array.from(
    document.querySelectorAll(".service-link-block")
  );
  const serviceImages = Array.from(
    document.querySelectorAll(".service-image-inner")
  );
  if (!serviceLinks.length || !serviceImages.length) {
    console.warn("Service links or CMS images not found.");
    return;
  }
  if (serviceLinks.length !== serviceImages.length) {
    console.warn(
      "CMS item count mismatch:",
      serviceLinks.length,
      serviceImages.length
    );
  }
  const count = Math.min(
    serviceLinks.length,
    serviceImages.length
  );

  // Prepare image layers
  serviceImages.forEach((image, index) => {
    gsap.set(image, {
      autoAlpha: 0,
      y: 20,
      position: "absolute",
      inset: 0,
      width: "100%",
      pointerEvents: "none"
    });

    image.classList.remove("active");
  });

  // Set the image container as a positioning context
  const imageList = serviceImages[0].parentElement;
  if (imageList) {
    imageList.style.position = "relative";
  }
  function activate(index) {
    if (index < 0 || index >= count) return;
    serviceLinks.forEach((link, i) => {
      const active = i === index;
      const text = link.querySelector(".service-text");
      const arrow = link.querySelector(".services-arrow.icon-1");
      const overlay = link.querySelector(".services-arrow.overy");
      link.classList.toggle("active", active);
      if (text) text.classList.toggle("active", active);
      if (arrow) arrow.classList.toggle("active", active);
      if (overlay) overlay.classList.toggle("active", active);
    });
    serviceImages.forEach((image, i) => {
      const active = i === index;
      image.classList.toggle("active", active);
      gsap.killTweensOf(image);
      gsap.to(image, {
        autoAlpha: active ? 1 : 0,
        y: active ? 0 : 20,
        duration: active ? 0.5 : 0.3,
        ease: active ? "power3.out" : "power2.out",
        overwrite: true
      });
    });
  }
  serviceLinks.slice(0, count).forEach((link, index) => {
    link.addEventListener("mouseenter", () => activate(index));
    link.addEventListener("focus", () => activate(index));
    link.addEventListener("click", (event) => {
      if (link.getAttribute("href") === "#") {
        event.preventDefault();
      }
      activate(index);
    });
  });

  // First CMS item active on load
  activate(0);
});
Pricing box hover interaction

This GSAP interaction activates pricing boxes on hover, updates active classes, and smoothly expands the active pricing image while collapsing inactive images. The first pricing box is active by default.


window.Webflow = window.Webflow || [];

window.Webflow.push(function () {
  function initPricingHover() {
    if (typeof gsap === "undefined") {
      setTimeout(initPricingHover, 100);
      return;
    }

    document.querySelectorAll(".pricing-section-left").forEach((section) => {
      const boxes = section.querySelectorAll(".pricing-box");

      if (!boxes.length) return;

      function setActive(activeBox) {
        boxes.forEach((box) => {
          const imageWrap = box.querySelector(".pricing-image-wrap");
          const isActive = box === activeBox;

          box.classList.toggle("active", isActive);

          if (imageWrap) {
            imageWrap.classList.toggle("active", isActive);

            gsap.to(imageWrap, {
              height: isActive ? "auto" : 0,
              duration: 0.5,
              ease: "power2.out",
              overwrite: true
            });
          }
        });
      }

      // First pricing box active on page load
      setActive(
        section.querySelector(".pricing-box.active") || boxes[0]
      );

      // Switch active class on hover
      boxes.forEach((box) => {
        box.addEventListener("mouseenter", () => {
          setActive(box);
        });
      });
    });
  }

  initPricingHover();
});
Counter on scroll

This script creates a number counter animation that runs when the element scrolls into view. The numbers animate from 0 to their final value using a scrambling number effect powered by GSAP.

<script>
//BLOG CARD HOVER (smooth: width + height, responsive)
window.Webflow = window.Webflow || [];
window.Webflow.push(function () {
  function init() {
    if (typeof gsap === "undefined") { setTimeout(init, 100); return; }
    var grid = document.querySelector(".blog-grid");
    if (!grid) return;

    var mm = gsap.matchMedia();
    mm.add({
      touch:  "(hover: none)",
      small:  "(max-width: 768px)",
      w992:   "(min-width: 992px)",
      w480:   "(min-width: 480px)",
      reduce: "(prefers-reduced-motion: reduce)"
    }, function (ctx) {
      var c = ctx.conditions, touch = c.touch, small = c.small;
      var base = small ? 250 : 300;
      var GROW = 1.2, H_MULTI = 1.43, H_SINGLE = 1.2;
      var DUR = c.reduce ? 0.01 : 0.7, EASE = "power2.out";

      var cards = Array.prototype.slice.call(grid.querySelectorAll(".blog-link-block"));
      var N = cards.length;
      var items = [], idxs = [], boxes = [], pr = {};
      var active = -1, raf = 0, leaveT = 0, ncols = 1, widened = false, hr = 1, cleanup = [];

      grid.style.alignItems = "center";

      cards.forEach(function (card, i) {
        var item = card;
        while (item.parentElement && item.parentElement !== grid) item = item.parentElement;
        item.style.alignSelf = "center";
        items.push(item);
        idxs.push(Array.prototype.indexOf.call(grid.children, item));
        var box = card.querySelector(".blog-image-block");
        boxes.push(box);
        pr["p" + i] = 0;
        if (box) { box.style.height = base + "px"; box.style.willChange = "height"; }
      });

      function colsCount() {
        return getComputedStyle(grid).gridTemplateColumns.split(" ").length;
      }

      // Ek j render: height + columns ek sathe (no jitter)
      function render() {
        var i, col;
        for (i = 0; i < N; i++) {
          if (boxes[i]) boxes[i].style.height = (base * (1 + (hr - 1) * pr["p" + i])).toFixed(2) + "px";
        }
        if (!widened) return;
        var d = GROW - 1, pc = [], P = 0, t = [];
        for (col = 0; col < ncols; col++) pc.push(0);
        for (i = 0; i < N; i++) { col = idxs[i] % ncols; pc[col] = pr["p" + i]; P += pc[col]; }
        for (col = 0; col < ncols; col++) {
          var fr = 1 + d * (pc[col] - (P - pc[col]) / (ncols - 1));
          t.push("minmax(0," + fr.toFixed(4) + "fr)");
        }
        grid.style.gridTemplateColumns = t.join(" ");
      }

      function go(idx) {
        var v = { duration: DUR, ease: EASE, overwrite: true, onUpdate: render };
        for (var i = 0; i < N; i++) v["p" + i] = (i === idx) ? 1 : 0;
        if (idx === -1) {
          v.onComplete = function () {
            if (active === -1) { grid.style.gridTemplateColumns = ""; widened = false; }
          };
        }
        gsap.to(pr, v);
      }
      function setActive(idx) {
        clearTimeout(leaveT); leaveT = 0;
        var n = colsCount();
        var wide = n > 1 && Math.ceil(N / n) === 1;
        if (wide) { ncols = n; }
        else if (widened) { grid.style.gridTemplateColumns = ""; }
        widened = wide;
        hr = wide ? H_MULTI : H_SINGLE;
        active = idx;
        go(idx);
      }
      function clearAll() { leaveT = 0; active = -1; go(-1); }
      function later(ms) { if (!leaveT) leaveT = setTimeout(clearAll, ms); }

      function cardIndex(t) {
        var el = t && t.closest ? t.closest(".blog-link-block") : null;
        return el ? cards.indexOf(el) : -1;
      }
      function listen(el, type, fn, opt) {
        el.addEventListener(type, fn, opt);
        cleanup.push(function () { el.removeEventListener(type, fn, opt); });
      }

      listen(grid, "focusin", function (e) {
        var i = cardIndex(e.target);
        if (i > -1 && i !== active) setActive(i);
      });
      listen(grid, "focusout", function () { later(60); });

      if (!touch) {
        // Mouse: gap ma jay to turant reset nai (flicker nai)
        listen(grid, "mousemove", function (e) {
          var i = cardIndex(e.target);
          if (i > -1) {
            clearTimeout(leaveT); leaveT = 0;
            if (i !== active) setActive(i);
          } else if (active !== -1) { later(140); }
        });
        listen(grid, "mouseleave", function () { later(60); });
      } else if (colsCount() === 1) {
        // Touch + 1 column: screen na vachche sauthi nazdik ek card
        var pick = function () {
          raf = 0;
          var vh = window.innerHeight, mid = vh / 2;
          var best = -1, bd = Infinity, ad = Infinity;
          items.forEach(function (it, i) {
            var r = it.getBoundingClientRect();
            var d = Math.abs(r.top + r.height / 2 - mid);
            if (i === active) ad = d;
            if (d < bd) { bd = d; best = i; }
          });
          if (best < 0 || bd > vh * 0.3) { if (active !== -1) clearAll(); return; }
          if (active === -1 || (best !== active && bd + 40 < ad)) setActive(best);
        };
        var sched = function () { if (!raf) raf = requestAnimationFrame(pick); };
        listen(window, "scroll", sched, { passive: true });
        listen(window, "resize", sched);
        sched();
      } else {
        // Touch + 2/4 column: tap thi active
        listen(document, "touchstart", function (e) {
          var i = cardIndex(e.target);
          if (i > -1) { if (i !== active) setActive(i); }
          else if (active !== -1) clearAll();
        }, { passive: true });
      }

      return function () {
        cleanup.forEach(function (f) { f(); });
        clearTimeout(leaveT);
        if (raf) cancelAnimationFrame(raf);
        gsap.killTweensOf(pr);
        grid.style.gridTemplateColumns = "";
        grid.style.alignItems = "";
        items.forEach(function (it) { it.style.alignSelf = ""; });
        boxes.forEach(function (b) { if (b) { b.style.height = ""; b.style.willChange = ""; } });
      };
    });
  }
  init();
});
</script>

Important notes

  • Always resize your images before uploading them. Large, unoptimized files can slow down your website, so choose the right size for the best performance.
  • Compress images: To improve site loading speed, compress your images to AVIF or WebP formats using the built-in Image Conversion tool.
  • Clean up: Before publishing your site, clean up unnecessary interactions and remove unused CSS styles to ensure optimal performance.
  • SEO: Before publishing your site, be sure to edit the Title tag, Meta description, Open graph image, and other SEO elements.
  • Audits panel: Before publishing your site, use Webflow’s Audit panel to identify and fix accessibility issues, ensuring your website is user-friendly and compliant.