Dropdown Menu Animation: Fast, Clear and Accessible
How to animate dropdown menus: opening from the trigger, timing, hover delays, closing behaviour, and the WAI-ARIA menu button pattern.
Core Takeaway
A dropdown should open from its trigger, quickly, and close even faster. Scale and fade from the button's edge in about 150 to 200 ms, avoid long staggered item animations, add small delays to hover menus so they do not flicker, and follow the menu button pattern so keyboard and screen reader users can open, navigate and close it.
Open from the trigger
Set the transform origin to the edge nearest the button so the menu appears to grow out of it. This spatial link tells people where the menu came from. A combination of a small scale and fade is enough.
Timing
Menus are used constantly, so speed matters more than flourish.
- Open in roughly 150 to 200 ms
- Close faster, or instantly
- Skip staggering items, or keep the stagger tiny
- Respond to clicks immediately; never delay the first frame
Hover menus
Nielsen Norman Group's guidance on drop-down menus warns about menus that open or close on accidental hover. Add a short delay before opening and before closing, and make the path from trigger to menu forgiving so diagonal mouse movement does not close it.
Accessibility
Follow the WAI-ARIA menu button pattern, or use a native select for simple choices. The trigger needs aria-expanded, the menu items need correct roles, arrow keys move between items, and Escape closes the menu and returns focus to the trigger.
Building this in ExodeUI
ExodeUI, which we make, is best for brand-moment menus such as our lantern dropdown, with states your code sets from a real menu button. For everyday product dropdowns, a short CSS transition is simpler.
Key Principles to Remember
- Grow the menu from the trigger's edge
- Open in about 150 to 200 ms; close faster
- Delay hover open and close slightly
- Follow the menu button pattern
Frequently Asked Questions
Sources
- Drop-Down Menus: Use Sparingly — Nielsen Norman Group
- Menu Button Pattern — W3C WAI-ARIA Authoring Practices