FAQ: Learn HTML - Common HTML Elements - Linking to Same Page

FAQ image

This community-built FAQ covers the “Linking to Same Page” exercise in Codecademy’s lessons on HTML.

The most popular questions on the exercise Linking to Same Page:

Join the Discussion. We Want to Hear From You!

Have a new question or can answer someone else’s? Reply (reply) to an existing thread!

Agree with a comment or answer? Like (like) to up-vote the contribution!

Need broader help or resources about HTML in general? Go here!

Want to take the conversation in a totally different direction? Join our wider discussions.

Learn more about how to use this guide.

Found a bug? Report it!

Have a question about your account, billing, Pro, or Pro Intensive? Reach out to our support team!

None of the above? Find out where to ask other questions here!

Other FAQs

The following are links to additional questions that our community has asked about this exercise:

  • This list will contain other frequently asked questions that aren’t quite as popular as the ones above.
  • Currently there have not been enough questions asked and answered about this exercise to populate this FAQ section.
  • This FAQ is built and maintained by you, the Codecademy community – help yourself and other learners like you by contributing!

Not seeing your question? It may still have been asked before – try searching for it by clicking the spyglass icon (search) in the top-right of this page. Still can’t find it? Ask it below by hitting the reply button below this post (reply).

1 Like

A post was split to a new topic: Forgot to close unordered list

Does the href have to be lowercase?


Lesson 10, linking to same page.
can i link to the id using ordered lists or only unordered lists?

1 Like

if the list elements contain anchor elements, then yes


I’m studying on HTML DOCUMENT STANDARDS/10.Linking to Same Page
I followed the intructions and system agreed to pass to next level,but when I checked back, I noticed something unexpected. When I click on the media at the local host side ( third line under The Brown Bear’ , it does not directly go to the line of media ( over the bear photo) What I see at top of the page is the line writing ‘3. Canada’ .Does that happen, because it’s the end of the page or is there a problem? Because other two links take you directly to the top of the page. Hope I did not ask complicated?:slight_smile:

1 Like

yep, its because of end of page. Html is just a markup language, there is happening so much under the hood


What does the # character do?


Bonjour, je ne comprends pas a quoi correspond

car pour l’exercice 10 j’ai réussi sans inclure
? merci
1 Like

Why on this exercise the ordered list opening tag is <ul> and not <ol> like previously explained?

UL is unordered list with bullets, as opposed to ordered list with numbers or letters.


Thanks! I just figured it out :relieved:


How come you need to use the # symbol when referencing an id tag? In the lesson we have it

. Wouldn’t we just be able to call "href=“habitat”? Or does the “#” only apply to ids?

That link will go nowhere. We must include the hash so the browser knows to look for a page fragment with id="habitat".

Correct, only ids in the markup. In CSS they symbolize the id selector.

#habitat {


I was wondering the same. Also whether it best to write the href # string full lout like #introduction or that short abbreviations like #intro are better.

I have a sense of what the answer will be (something along the line off readability for other developers) but wonder if there is a best practice answer :wink:

There is no better in this example, only what we subjectively prefer. To be objective we should leave no room for ambiguity so abbreviations should probably be avoided, thus giving the reader a clear picture what the id denotes. A familiar abbreviation, like ‘intro’ is perfectly fine so long as we associate it immediately with the word ‘introduction’.


I’m very confused as to why the exercise does not register my link for “habitat.” I included a photo. Thoughts?


I was doing just fine until I got to “Linking To Same Page.” # 1. Was a breeze. But the 2nd part of the exercise has me stumped.

1 Like

Any link that looks like this,

<a href="#">Link text</a>

is requesting the current page landing point.

1 Like