# Hide Pages And Sections

## Hide Pages And Sections

There are several ways to hide content in Taxo. The right one depends on
whether you want the change on one page, one collection item, or the whole
site.

These steps show the files of the Astro edition. In the Tina and Sanity editions, the same fields are in the forms: `enable` is **Enable** in **Section defaults** at `/admin/` and in **Sections** in the Studio, and `draft` is the page's draft field.

### 1. Hide A Shared Section Everywhere
Edit the shared section Markdown file and set `enable: false`.

```yaml
# src/content/sections/english/cta-section.md
enable: false
```

Use this when the section should disappear on **every page that uses it**.

The three features grid sections (`features-grid.md`, `features-grid-two.md`, `features-grid-three.md`) don't read this field. To hide one of them, remove it from the page file: see step 6.

### 2. Hide One Item Inside A Section
Many section lists also support `enable: false` at the item level:

```yaml
list:
  - enable: true
    title: "Basic"
  - enable: false
    title: "Enterprise"
```

This pattern works for:

- pricing cards
- team members
- features

The FAQ lists show every item, so delete an FAQ item to remove it.

### 3. Hide A Menu Item Only
If the page should still exist but should not appear in the header navigation:

```json
{
  "enable": false,
  "name": "Pricing",
  "url": "/pricing/"
}
```

### 4. Hide A Single Page From Production
Set `draft: true` in that page or collection entry:

```yaml
---
title: "Privacy Policy"
draft: true
---
```

For collection entries such as blog posts, services, and case studies, Taxo
filters draft items out in production.

### 5. Hide An Entire Collection Temporarily
If you set `draft: true` in a collection `-index.md`, Taxo will hide the list
page in production. The entries in that collection still build, so mark them as
draft too if they should not be published.

Examples (these are `-index.mdx` in the Tina edition):

- `src/content/blog/english/-index.md`
- `src/content/services/english/-index.md`
- `src/content/case-studies/english/-index.md`

### 6. Hide A Section On Only One Page
Do **not** set the shared section file to `enable: false` if the section should
stay visible elsewhere.

Instead, edit the page file and remove that render call:

```astro
// src/pages/[...lang]/index.astro
<HeroSection />
<FeaturesGrid />
{/* Remove or comment out this line for this page only */}
<ServicesSection />
```

### 7. Use Page-Level Section Overrides
Some pages pass section data from frontmatter into shared components.
That lets you disable a section only on that page:

```yaml
# src/content/team/english/-index.md
teamSection:
  enable: false
```

This works because `TeamSection.astro` merges page overrides with the default
section content.

In the Tina edition, every page's form has these blocks: see [What Is Editable In Tina](../../features/what-is-editable-tina/). In the Sanity edition, only some pages have **Sections on this page** rows: see [What Is Editable In Sanity](../../features/what-is-editable-sanity/).

### Quick Rule Of Thumb
- Want to hide it everywhere: change `src/content/sections/...`
- Want to hide it from the header menu only: change `menu.<lang>.json`
- Want to hide one page in production: use `draft: true`
- Want to hide it on just one route: edit the page file or use a page-level
  section override