By default, The Events Calendar uses the slug /venue for all single Venue pages. For example, a single venue URL might look like yourdomain.com/venue/the-city-hall/. If you want to change this URL base to something else—like /location or /space—you can do so with a simple code snippet.
This is a great approach for customizing the permalinks on your site to better match your branding or terminology.
Using a Code Snippet
The following code uses the tribe_events_register_venue_type_args filter, which allows you to modify the arguments used when registering the Venues post type, including its rewrite slug.
add_filter( 'tribe_events_register_venue_type_args', function( $args ) {
$args['rewrite']['slug'] = 'location'; // Change 'location' to your preferred slug
return $args;
} );
How to Use the Code
- Add the snippet to your site’s
functions.phpfile (recommended only if using a child theme) or use a code snippet plugin. - Replace the word
locationon line 2 with your desired slug (e.g.,space,place, orsite). - Crucially, flush your permalinks after adding or modifying the snippet. You must do this for the change to take effect:
- Navigate to Settings → Permalinks in your WordPress dashboard.
- Simply click the Save Changes button (you don’t need to change any settings).
After following these steps, your new Venue URLs will use the custom slug, for example: yourdomain.com/location/the-city-hall/.
Flushing Permalinks
Whenever you change a rewrite rule (like a slug), WordPress needs to regenerate its internal structure of URLs. If you skip the step of visiting the Settings → Permalinks page and clicking Save Changes, your venue pages may result in 404 errors. Always flush permalinks after changing a slug.