Rather than 'opting out' of including certain pages, you can 'opt in' to include only the pages you do want included in your navigation. This is useful if you have a large number of pages.
Include a menu
variable in the front matter of every page you do want included in the navigation:
---
layout: blog
title: Blog
menu: main
permalink: /blog/
---
And then add an if statement where your navigation is generated:
<ul>
{% for page in site.pages %}
{% if page.menu == 'main' %}
<li><a href="{{ page.url | prepend: site.baseurl }}">{{ page.title }}</a></li>
{% endif %}
{% endfor %}
</ul>
This is likely to be in _layouts/default.html
or possibly _includes/header.html
.
Thanks to David Jaquel's answer on this question for the inspiration: Excluding page from Jekyll navigation bar