How to Make WWWow with
star image
Jamstack / Headless
A free guide!
  • Impress Your Visitors with 3 Main Web Animation Techniques: for Beginners, Regulars, and Advanced

Impress Your Visitors with 3 Main Web Animation Techniques: for Beginners, Regulars, and Advanced

From basic animated icons and banners through button hovers and navigation transitions to advanced neumorphism, liquid motion or scrollytelling… web animation effects have become crucial if you’re serious about good UX. In the article, we systematize the main directions in web animation design for making your decision easy-peasy.

web_animation_

From basic animated icons and banners through button hovers and navigation transitions to advanced neumorphism, liquid motion or scrollytelling (animated storytelling)… website animation effects have become crucial if you’re serious about good UX. What’s more, each of them is a powerful tool to guide the user’s attention, express the brand’s concepts in a very enticing way and let you stand out from the competition.

Web animations have grown into a large domain within the wider world of designing websites, which can be separated into several sub-trends. There are so many possible solutions that you can understandably start asking yourself: what should I go with, what kind of animation effect will be most suitable for my needs, and which animation technique should I choose for my web design?

This is what this article serves to answer: to systematize the main directions in web animation design for making your decision easy-peasy. It’s not about cinema animation, however it's a similarly intriguing topic!

web_animation_examples

When we say web animations, we mean, for example:

  • Loading animations

  • Scrolling animations

  • Hover animations

  • Animated backgrounds

  • Page motion animations

  • Dynamic menu options

  • Welcoming animations

  • Slideshows

  • UI animations

Let’s check out the possible approaches and tools to make your web page trending in this matter!

How to Start Creating Web Animations?

According to HTTP Web Almanac, 77% of all mobile websites and 73% of all desktop pages have been built with animations onsite. This is surprising considering that 94% of first impressions are visual-related, so we can anticipate that the number of websites equipped with animations will be growing.

As the demand is extreme and there are tons of possible solutions, the key is not to get lost in the ocean of possibilities. Where should we start our journey? Even if you have the best map in the world, you won’t reach your travel destination if you don’t know where you are right now, so the first step is to rethink our product and definethe purpose of using web animations.

Before you ask yourself ‘How to animate a website?’, you should acknowledge more general aspects of creating websites: who are we, as the organization? What’s our website all about and what’s the reason we’re creating it? What are our expectations of the user's behavior?

Forget about flash animations. They're risky and unsupported. There are a few better strategies of applying changes or adding animation to web pages, all of which can help you to choose what's best for your business.

The Three Main Ways to Add Web Animations to Your Site

1. An Animation-Focused Website Update

The first approach is adding motion and web animation just to keep the design consistent with ongoing general design trends. You obviously don’t want your possible customer to have the impression of visiting an outdated website!

However, nowadays, a redesign is not only about changing colors and graphics. Among web development specialists, we tend to say: user experience is the key, so there’s no point in website redesign without improving this experience. And there’s no improving the experience if you’re just throwing the content out there randomly, without the well-thought-out interconnections between animations and the rest of the site’s content.

Animations Should Improve User Experience

User experience is the key, so there's no point in website redesign without improving this experience. And there's no improving the experience if you're just throwing the content out there randomly, without the well-thought-out interconnections between animations and the rest of the site's content.

Yes, there’s no modern user interface without smooth page transitions, animated loadings or plopping chats… and that’s a minimum plan to follow if you want to keep your site up to date. But you need to do it carefully, with an understanding of the user's expectations.

2. Keeping Your Web Page Up-To-Date with Regard to Animations

The second option is a slight level up: using web animations to catch the user's attention to the key functionalities of your app or to the button you want to be clicked. There is a scientifically proven design rule that movement is the most catching for the human eye. That's the perfect phenomenon to use in improving your eCommerce conversion! But as it’s very powerful, this strategy needs some consideration, because if too many items will move, we can accidentally make our users a little wall eyed and even achieve the opposite effect.

3. Making a Wow Effect for Your Web Visitors

Let’s go crazy and impress your customers with a ‘wow’ effect. On-scroll animations, breathing flat design, partly-animated photos and pictures… For example, stylish hair waving effects on what used to be regular pictures can make a huge difference on a website of a coiffeur salon. With contemporary stack solutions, there are plenty of possibilities!

It would take longer to design and develop, but if it’s consistent with your brand’s concepts, it can be a huge opportunity to stand out from the crowd. Depending on the business you operate in, you may have only one chance for a ‘wow’ effect, and sometimes design speaks louder than words.

So, which one to choose? There’s no good or bad choice here, as there is no golden rule applicable to every business. Regardless of the strategy you choose, we’re going to sort out and systemize the different approaches to animations in web design to make you aware of their specificity. Let’s take a look!

Web Animation Styles

Less is More: Power of Pure CSS Animation

Let’s start our journey from keeping the design consistent. Good news: you don’t need to spend ages using huge external libraries and complicated tools to give your page a fresh look.

Stylish button hover effects, navigation transitions, smooth scrolls – they’re so common in modern web development that, at Naturaily, we even had a discussion whether we should keep calling them animations. Today, the website feels a little rough if it misses these minimalistic transitions, so it’s worth spending a few additional hours to have them polished and pleasing to the user’s aesthetic sense.

CSS Animations Pros & Cons

The undiscussable advantage of this type of solution is its lightness. CSS animations don't impact Google Web Core Vitals to a noticeably negative extent, as it sometimes becomes a problem with heavier solutions being wrongly implemented. You also don’t need a high class animation expert in the team, as simple solutions don't require any uncommon programming skills.

With a little effort, you can improve your interaction with customers and show you’re a serious player without technically saying a word. You don’t have to make complicated scenarios. It’s enough to use some CSS transitions and eases, add interesting button hover effects, care about providing a remarkable navigation experience, sprinkle your page with a little animated decorator or liven the website up thanks to CSS animated backgrounds… If everything is just in the right place, users will feel it from the first second spent on your web pages.

But as it’s a perfect place to start an adventure with web animations, for some it may be not enough. CSS animations are extremely powerful, but still have their limitations, especially if you’re more into complicated scenarios or complex between-element dependencies.

Level Up: JS Libraries for Animation

If simple CSS effects are not enough for you, consider library-supported animations. They need a little more effort and some knowledge of tools, but they are ultimately not rocket science. It’s definitely a level up worth trying!

Opposite to a particular project’s code that one web designer has had to work on from scratch, libraries are commonly used by a broad community of web developers. This includes those who work according to the Jamstack approach that we’ve been in love with for a few years now.

what_is_jamstack_

Wish to learn more about What is Jamstack?

If yes, that's great. We did our best so you can grasp the topic easily!

Libraries simply have a huge chance to be well tested by the community and better optimized, which a single projects’ code can’t count on. JS libraries for animation are basically sets of professional looking components, functions, JS objects, gestures, movements’ generators, or events that can be used for creating a very diverse user experience.

JavaScript Easing Functions

One such example comes in the form of predefined easing functions. Easing is the way elements transform and are the core of an animation’s feel. Technically, they’re specified as the function – a rate of change of a parameter over time. Using functions shortens the time needed to achieve the effect we strive for. How is that?

Web developers, for example, usually want to change many parameters with different smoothness ratios at one single time. If the goal is to achieve perfectly balanced web animations (neither trivial nor exaggerated), it would be really complicated to code manually. We don’t want to follow this scenario, as it offers only long hours of work and a risk of funny effects instead of the sophisticated web animations we dreamed of.

You don’t have to reinvent the wheel if you have predefined solutions, right?

Framer Motion for React Pros & Cons

One of possible animation tools is Framer Motion for React. As it’s a library coming from a prototyping tool, it’s definitely a good pick for interface animations. Simple yet impressive is what we want to achieve and, with tools like this one, it’s at our fingertips. Framer Motion’s main benefits include:

  • Fully open-source

  • High accessibility possibilities

  • Handles the most important gestures, such as drag, pan, hover, and tap, which can be used to address almost any web motion desire

  • Supports CSS properties and variables

  • Offers multiple extra, fully customizable motion events and transition functions that you wouldn’t think of

  • Uses server-side rendering

  • It’s optimized for React, which is one of the most popular JavaScript libraries

dajemy_slowo_case_study

Check how we used Framer Motion animations in on of our Jamstack development projects: dajemyslowo.com

Check

Framer Motion for React Drawbacks

Unfortunately, every rose has its thorns and Framer Motion is no exception. The tool provides a lot of additional event listeners, which makes browsers busy with looking for user’s clicks and scrolls to run our animations accordingly. Some complex counting can also lead to very heavy performance. Developers may need to use more wrappers than usual, which is not a perfect clean coding practice and can have an impact on a project’s future development or modifications.

And last but not least – it can be a challenge to handle the responsiveness. We need to be aware of potential risks, but it’s all about the particular case here – if the tool is chosen responsibly and then used correctly, a whole new universe of web animations can be free for users to explore.

Other JavaScript animation libraries that are worth your attention include:

  • Mo.js: best for customization purposes

  • Vivus.js: best for SVG animations

  • Typed.js: best for text typing effect

  • Three.js: best for creating impressing 3D scenes; very complex tool

  • Anime.js: best for multipurpose projects (with this library, you can animate HTML, JS, CSS, SVG)

  • Animate.css: best for basic animations (it’s not JavaScript based)

web_animation_libraries

Beautiful made easy – SVG or Lottie

Have you ever come across a beautiful illustration with slight movements included? Humans waving their legs happily, cartoon bicycles in motion, graphics of a computer or smartphone with moving elements, floating geometrical figures… Well, there’s a big chance it was one of two popular solutions: animated SVG or Lottie Files.

Scalable Vector Graphics (SVG)

SVG is an abbreviation from Scalable Vector Graphics format. It’s extremely powerful because it’s the code, not just a plain graphic file. This changes everything. Programmers can do a little magic and breathe new life into static figures. They can do it by adding movement to elements of the prepared SVG file with the use of CSS properties or JavaScript coding. However, it also means that web designers will sometimes need to work on one element after another.

But they can also often automate the process of creating SVG animations. There’s a variety of modern tools that allow for work on bigger sets of to-be-animated elements (takie SVGator as an example).

SVG Animations Pros & Cons

Every solution has its light and dark sides and that’s why it’s crucial to define what we want to achieve from the very beginning. Animating SVG files manually is more laborious, but a programmer’s experienced eye can be crucial for keeping things optimized and inline with good practices.

On the other hand, pre-made animated SVGs can provide more stunning effects with more complicated and graphically polished web animations. Nonetheless, as is often the case, most secrets are hidden under the hood, so we can’t see how well it’s optimized in the end. Unless you have a web designer with a little twist for animations!

Jamstack_developers_

Wish to learn more about Why developers choose Jamstack more often?

If yes, that's great. We did our best so you can grasp the topic easily!

Lottie Animations

Lottie is another solution worth mentioning, as it’s also not the plain graphic but the code itself. This time it’s not an SVG, but a JSON format.

Lottie Animation Pros & Cons

You already know the first of the main benefits of using code files for animations in web design: they can be easily modified. The second goes like this: chunks of code are always smaller and lighter than image files, which makes them a good choice if you want to use fancy graphics that will not ruin Google Web Core Vitals on the way. The only drawback to find here is that designing and using JSON files in animation projects may require a few specific skills in your team, as well as Lottie dedicated tools.

Using SVG properties or Lottie formats can add superb effects to your page. They will be light and very stable, no matter the device the target audience is using to experience your web page.

Let’s Go Crazy: GSAP and Other Complex Tools

Okay, what if it’s time to show and shine, and we want a brand new experience for our users? Let’s assume we really want to make them sigh of delight, stunned with the very alive design and surprised with the story you have to tell. We live in crazy times and have plenty of tools to choose, but, as the case is becoming more complex, there are more things that can also go wrong here.

You have to admit – some web animations can really make a strong impression. But it’s also easy to make them cheesy and end up with a cliche. That’s why defining a purpose and thinking through the design process is so important in this case. Through hardships to the stars – if we want a ‘wow’ effect, we need a ‘wow’ strategy.

GSAP Animations Pros & Cons

One of the possible tools to use is GSAP. It’s the perfect pick for creating web animations that are complex, so you can define whole scenarios and create some dependencies between components.

GSAP (GreenSock Animation Platform)

GSAP is the perfect pick for creating web animations that are complex, so you can define whole scenarios and create some dependencies between components. A web designer can easily create a unique animated script by merging thousands of variables. This tool also facilitates setting up the specific behavior of used website elements, such a scroll behavior.

A web designer can easily create a unique animated script by merging thousands of variables. This tool also facilitates setting up the specific behavior of used website elements, such as scroll behavior. GSAP (GreenSock Animation Platform) offers great features and plugins to manage it promptly. And it would be very problematic and time-consuming to modify the effect of the scroller, while maintaining good performance of the website at the same time, without a dedicated tool like GSAP.

Of course there are not only splendors and, as with every other tool, it can be misused and become a huge load for the page’s speed indexes. It’s also not fully satisfying to handle responsiveness with, but with every next release it’s getting slightly better, so it’s worth keeping an eye on.

How to Add Animations to Websites

Important Decisions First

Creating animations for your site may not be easy, as there are many traps lying in wait. You can do almost anything technically and aesthetically, but what if you simply don’t know how to start?

The secret is all about matching the user’s preferences with the business environment you operate in. The first and most crucial – it’s key to make important decisions first. Do we want web animations at all? What are they supposed to do? What do we want to achieve?

Sometimes things are hard to name, so combining mood boards and collecting inspirations is a good strategy to define needs, visions and ideas. Being on the same page is essential to communicate effectively, especially with your web development team.

Defining Responsibilities & Principles

If we finally know what we want to achieve, it’s good to define responsibilities. Should we work with a dedicated designer? Do we need to make precisely defined draft visualizations to be sure whether the final product matches our expectations? Or maybe it’s enough to define only the baseline principles and use developers' practical experience, since web animations are not the core of how our product communicates? As it has already said many times – there is no golden solution, so it needs to be thought out and tailor-made for defined needs.

‘Is it really that important?’, you may say. Exactly, what can go wrong here? Well, a catastrophe can wait just around the corner:

  • The final product doesn’t match the expectations or, what’s worse, we’re achieving the opposite effects of what’s expected in regards to user behavior.

  • Both the scope and costs can grow enormously as there is no link between design and development, or some decisions were made when the product was already on the table.

  • Overusing or using wrongly matched tools can crush our Web Core Vitals and make Google bots angry on our page.

These are the scenarios we want to evade, and that’s why these initial steps are so valuable!

3… 2… 1… action!

But hey, don’t be a pessimist here, as it looks like we have an awesome project to do! We already know that animation in the modern web has grown into a large domain and it’s worth our interest if we want to keep sites trending. We see it’s not a purpose itself, but a powerful way to guide the user’s attention, express the brand’s concepts and stand out from the crowd.

All the possible scenarios and tools are just instruments in our hands and there’s no all-purpose guide or one source of universal truth. The key is who you are, what your business is and what you want to achieve. If we define the purpose, we can make all the tools work for our case, not the opposite. Then, the whole process has a huge chance to lead us directly to what we call a success.

Still have some doubts? Just get in touch with us, Naturaily, and we’ll try to cover anything!

Let's talk about Jamstack!

Contact us and we'll warmly introduce you to the vast world of Jamstack web development!

GET AN ESTIMATE