How To Fix Elementor's Scroll To Anchor Issue On Mobile

Rifat Elementor Dec 14, 2023

Elementor is a popular page builder plugin for WordPress that allows users to create stunning and interactive websites without any coding knowledge. One of its many features is the ability to create anchor links that scroll to specific sections on a page. However, some users have reported an issue with these anchor links not working properly on mobile devices, which can be frustrating for both website owners and visitors.

If you're experiencing this issue, don't worry! There are several solutions available that can help you fix Elementor's scroll-to-anchor issue in mobile. In this guide, we'll explore some of the most effective ways to troubleshoot and resolve this problem, including adjusting your website's settings, using custom code, and installing plugins. With these tips and tricks, you'll be able to ensure that your website's anchor links work smoothly and seamlessly across all devices, providing a better user experience for your visitors.

In Elementor, what is an Anchor?

The jump menu is another name for the anchor menu. This anchor ID will lead you to the place you've specified as a preference. The anchor menu enables your viewers to navigate to the next page, click on any link, and do any search. This is, in general, the operator of a WordPress website.

How Using Anchor on Your Site Can Help You

An anchor can serve multiple purposes. This linkage optimizes the surfing experience on your website. The advantages are as follows:

Improves User Experience

Anchor links facilitate browsing. Your visitors may simply click, tap, and choose the desired service to get. This improves the online experience.

Allows You to Return to the Content's Top

If you are scrolling too much, anchor links might assist you in going to the top of the page. This tool will save you time and keep you on track.

Ensures Efficient Browsing

In addition to scrolling, anchor links can also be used for clicking, returning to the previous page, etc. It facilitates efficient browsing.

Quicker Performance

You can obtain an immediate response from the command. Instead of inputting instructions, anchor links allow for speedier navigation.

Why Elementor's Scroll to Anchor Feature Does Not Work on Mobile

It is tough to explain why the scroll to anchor in Elementor does not work on mobile. However, after a comprehensive investigation, we were able to determine the following facts:

Insufficient targets

If your page lacks target links, such as Sobre-Agencia, Como-Fazer, Services, contacts, etc. This may be a factor preventing your scroll link from functioning.

Extensions Cause Difficulty

If your Android device is loaded with extensions, this may also be blocking the scroll feature from operating.

Too Many Plugins

If your website has an excessive number of plugins, this might be another reason why your WordPress anchor has ceased responding. Additional plugins clash with one another. This may cause your website to become inaccessible.

Poor Server Condition

If your website's server is unable to handle plugins, this might be a cause preventing your links from functioning.

5 of the Most Effective Tips to Fix Elementor Scroll to Anchor

elementor anchor

Despite the reason why Elementor scroll to anchor has been ineffective, the following tips will assist you in repairing your website. Here goes;  

Creating Targets

Your scroll link might not function if your page has no target links. For this reason, you need first construct target links and then emphasize them in the following manner:

First, select your theme and enter the following codes into your sheet.

.menu-item a{
     Color: black;


}

If you like to be informed whether or not your link is visible to your audience, choose this option. To do so, provide the following CSS:

.menu-itema.mPS2id-highlight{
      color: red;
}

Use a Javascript Filter

For the Elementor anchor widget, a javascript filter can be used. Run the following programs to add the filter:

add_action( 'wp_footer', function() {
    if ( ! defined( 'ELEMENTOR_VERSION' ) ) {
        return;
    }
    ?>
    <script>
        jQuery( function( $ ) {
            $( window ).on( 'elementor/frontend/init', function() {

                elementorFrontend.hooks.addFilter( 'frontend/handlers/menu_anchor/scroll_top_distance', function( scrollTop ) {
                    var isMobile = $(window).width() <= 760;
                    if (isMobile) {
                        return scrollTop - 1000;
                    } else {
                        return scrollTop;
                    }   
                } ); 
            } );
        } );
    </script>
    <?php
} );

Adjust the Scrolling

Adjust the offset scrolling while the menu is open in mobile mode as an alternative solution.

Prevent the Menu from Closing 

Although this is not a viable solution, the only option is to keep the menu bar drop-down open. This will facilitate navigation if your scroll anchor becomes stuck.

Choose the Default Theme

One thing you may do to fix the anchor icon on your site is to fix the icon. Choose the default theme for WordPress. This is superior.

How to Easily Add an Anchor to Your Elementor Website Using a Plugin

A plugin is the most convenient method for adding an anchor link to a website. To add an anchor, please follow the below steps:

Install the link-adding plugin before adding any links. Then, build a shortcode block where the anchor links should appear. Execute the following shortcodes:

[ps2id id='section-1'/]

Insert the anchor links into a brand-new shortcode block. Put it wherever you want the link to appear. Execute the following  codes:

[ps2id url='#some-id']link text[/ps2id]

Then, replace 'some-id' with the constructed anchor name and link-text with the desired anchor. Save the changes now. You are Done.

5 Best Anchor and Scroll Plugins

There are dozens of plugins that greatly improve the accessibility of connecting. Following a comprehensive investigation, we propose the five anchor plugins listed below as the finest.

Add Anchor Links

The Add Anchor Links plugin is a powerful tool that enables website owners to create anchor links for heading tags in their posts, similar to how Github creates links within its Readme.md files. This plugin is incredibly reliable and inserts anchor links into the selected headings and content elements, ensuring a seamless user experience for website visitors. Additionally, Add Anchor Links is PHP(5.6) and PHP 7 compliant, making it compatible with a wide range of website configurations. Users can disable CSS and specify the post type to which anchor links will be added, providing flexibility and control over the plugin's functionality. Overall, Add Anchor Links is an essential plugin for any website owner looking to optimize their content for a better user experience.

Key Features

  • Select the post type where the anchor links will be added.
  • Disable CSS.
  • PHP (5.6) & PHP 7 Compatible

Page Scroll To ID

Page scroll to id is a powerful plugin that enhances user experience by replacing the traditional "jumping" behavior of browsers with a smooth scrolling animation when clicking links containing the href value "#". It offers all the necessary tools and advanced functionalities for single-page websites, in-page navigation, and back-to-top links. With over 30 easing types and adjustable scrolling animation duration, users can customize their scrolling experience. The plugin also highlights links and targets with ready-to-use CSS classes and allows for vertical and/or horizontal scrolling. Additionally, it features offset scrolling by pixels or element selectors with custom expressions and link-specific options like scrolling duration and highlight target. This plugin can improve website navigation and provide a more pleasant user experience.

Key Features

  • Adjustable scrolling animation
  • Vertical & horizontal scrolling
  • Offset scrolling by pixels
  • Link and target highlighting
  • Scrolling on different pages
  • Insert link and target id buttons

Ultimate Blocks

Ultimate Blocks is a WordPress plugin that offers a vast collection of more than 18+ blocks with multiple functionalities combined under one umbrella. This plugin is a great option for those looking for a content table block plugin with anchor link options. The Table of Content Block allows you to create an automated table of content with just one click, making it easy for users to jump to the section they want to read. Additionally, you can activate or deactivate smooth scrolling and customize the title, background, list color, and list icon color. Overall, Ultimate Blocks is a comprehensive plugin that can save you time and effort in creating content for your website.

Key Features

  • Scroll Offset Adjustment
  • Smooth Scrolling
  • Romanize Anchor Links
  • Remove Diacritics from Anchor Links
  • List Alignment
  • 18+ Useful Blocks
  • Content List Style
  • Split Table of Contents into Columns

Anchor Block

The Anchor Block plugin provides an easy solution to add link anchors to your website's content using the Gutenberg Block Editor. It comes with a dedicated block that allows you to add an ID for your anchor and an optional top margin. With this plugin, you can generate internal links to every section of your pages with ease, making it an essential tool for improving your website's user experience. Although it does not come with fancy scrolling animations, Anchor Block is straightforward and user-friendly, making it a hassle-free way to add link anchors to your website's content.

Key Features

  • Easy-to-Use Plugin
  • Dedicated Block for Gutenberg Block Editor
  • Add ID for your Anchor
  • Option to Add Optional Top Margin in Pixel
  • Front-End Rendering with an Anchor
  • Custom Link Menu Item

Easy Smooth Scroll Links

Easy Smooth Scroll Links is a powerful plugin that allows users to apply scrolling animations to page anchors and smooth scroll in an easy and hassle-free way. With over 30 scrolling animation effects to choose from, users can customize the scroll speed and offset value to fit their preferences. The plugin also supports the use of shortcodes, making it easy to implement on any page builder, and includes a Visual Editor Anchor Button for easy use in the Visual Editor without shortcodes. Compatible with all major browsers, Easy Smooth Scroll Links is a must-have tool for anyone looking to enhance their website's user experience.

Key Features

  • Adjust Scrolling Speed & Offset Value
  • 30 Scrolling Animation Effects
  • Visual Editor Anchor Button
  • Shortcode Support
  • Exclude Certain Anchors from Scrolling
  • Works on All Major Browsers

Wrapping Up

Every website owner desires a fully-functional WordPress website. Your users may be disappointed if it does not function properly. The inability of Elementor to scroll to an anchor on mobile is a common issue that every website owner encounters. To simplify your life, we have highlighted the most effective hacks. We believe that this information will assist you in repairing yours.

Divi WordPress Theme