Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: OpenID Connect / OAuth client 3.0.0-alpha9 New alpha version released for module openid_connect (3.0.0-alpha9). Release: Opensolr Search 4.5.0 Minor update available for module opensolr_search (4.5.0). Release: Timelinr 1.0.1 Minor update available for module timelinr (1.0.1). Usage Milestone: Simplify Module simplify crossed 10,000 active installs. Usage Milestone: Views Reference Filter Module entityreference_filter crossed 10,000 active installs. Usage Milestone: Dropdown Language Module dropdown_language crossed 10,000 active installs. Usage Milestone: Paragraphs Browser Module paragraphs_browser crossed 10,000 active installs. Usage Milestone: OpenAPI Module openapi crossed 10,000 active installs. Usage Milestone: Decoupled Router Module decoupled_router crossed 10,000 active installs. Module Revived: Entityqueue Buttons 1.1.2 Module entityqueue_buttons updated after 8 months of inactivity (1.1.2).

Rabbit Hole

64,752 sites Security covered Drupal 9–11
View on drupal.org

This module allows you to control what happens when an entity is viewed directly on its own page. You can choose to deny access, show a "page not found" error, redirect to another URL, or allow the default behavior, and configure these settings per content type or individual item. This is useful for entities that are meant to be displayed in other contexts, rather than through their own dedicated URL.

What is this?

Rabbit Hole is a module that adds the ability to control what should happen when an entity is being viewed at its own page.

Perhaps you have a content type that never should be displayed on its own page, like an image content type that's displayed in a carousel. Rabbit Hole can prevent this node from being accessible on its own page, through node/xxx.

Options

This works by providing multiple options to control what should happen when the entity is being viewed at its own page. You have the ability to

  • Deliver an access denied page.
  • Deliver a page not found page.
  • Issue a page redirect to any path or external url.
  • Or simply display the entity (regular behavior).

This is configurable per bundle and per entity. There is also a permission that lets certain roles override Rabbit Hole completely.

Supported entities

Version Supported entities 8.x-1.x (stable, security fixes only) Nodes, Taxonomy terms, Users, Media entities, Commerce products, Groups, Files, Paragraph Library items
2.0.x (alpha, future version) All content entities 🥳

Additions

There is support for tokens when you are using the redirect option. However, it's recommended to install the Token module, which will provide you with a table of the available tokens.

Initial module development was sponsored by Odd Hill.

Rabbit Hole 2.0.0 development was sponsored by Evolving Web and DevBranch.

Additional modules

  • Rabbit hole href link alter, that rewrites the canonical link href directly to the redirect target instead of the entity to avoid the redirect.

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

3 tracked projects depend on this one

Activity

Tracked releases
4
Tracked since
Jan 2025
Latest release
5 months ago
Releases (12 mo)
3 ▲ from 1
Maintenance
Active

Release Timeline

Releases

Version Type Core Release date
2.0.0-beta2 Pre-release 9–11 Mar 16, 2026
8.x-1.2 Stable 9–11 Mar 16, 2026
8.x-1.1 Stable 9–11 Jan 13, 2026
2.0.0-beta1 Pre-release 9–11 Jan 14, 2025