<- Documentation

Last edited on June 8, 2021

Link to a section on your page.

You can make a link that scrolls to a specific section in your site. Here's an example:

Step 1: Create an Embed Code on top of the target section.

For example, you want it to scroll below this line. You should add an embed code like this right below the divider.


It should link here

To add an embed code:

  1. Type /embed . It will show something like the image above

  2. Click "Code" tab. Insert the code in the provided text area.

Here's the code to add:

<div id="unique-link-here"></div>

You can replace unique-link-here with any unique text, so if you have 3 links and 3 different sections in your site, you can have unique-link-1 , unique-link-2 , and unique-link-3 .

Step 2: Adding a link that goes to that section

If your code for the embed on Step 1 is:

<div id="unique-link-here"></div>

then your link would be #unique-link-here . So you can add a link like this:

Step 3 (Optional): Add smooth scrolling

You may notice that the page "jumps" to the section when you press the link. To make it scroll smoothly to the section:

  1. Go to Site Settings > Code Injection
  2. Add the code below to Site Header
<style>html {  scroll-behavior: smooth;}</style>

It should look like this:

That's it! 🎉

Your link should now be able to scroll to the target section.


Made in Typedream