There are 5 navigation nodes on the top link bar. enter image description here

I tried to get top navigation from a sharepoint site by using JSOM or CSOM but it returns more than 5 navigation nodes as the following:

  • German
    Page not found
    Test Test2 Test3

In Navigation Settings page, I used: "Structural Navigation" as below: enter image description here

I have no idea why it returns more than 5 nodes. Can someone help me?


  • Can you check pages library? The additional pages would be available there Aug 9, 2016 at 4:39
  • @MonicaJagani: You are correct. They are in Pages library. How can I know to ignore these pages? I want to get the same things as i see on the top link bar. Thanks!
    – Hon Bien
    Aug 9, 2016 at 6:35

1 Answer 1


Actually the top bar have limited space to show all so it picks latest links only .For test purpose you can try to hide 2 or 3 links from top bar, you will start viewing other links like error page .....

So ideally jsom/csom is returning correct results whereas SharePoint top bar shows links based on available space.

If possible, try to get latest pages using REST api (top 5 , orderby - created desc) to get limited result set

  • I just wonder. It shows exactly what we see in Navigation Settings page but from data source (get by REST/ JSOM) then there are more items. It has enough space to display > 5 navigation nodes and the maximum number of navigation to show is 20. I also checked all properties of navigation nodes then no different: such as IsVisible, IsDocLib, ... Thanks for your help!
    – Hon Bien
    Aug 9, 2016 at 9:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.