Customize Download URLs in GravityExport
GravityExport lets you securely share form data via downloadable URLs. By default, these URLs include the slug gravityexport, making them look like:
example.com/gravityexport/0800fc577294c34e0b28ad2839435945
While functional, this default structure isn’t always ideal for branding or clarity. Fortunately, you can customize the slug to match your site’s purpose better.
> Note: By default, you can use gravityexport, gravityexport-lite, or gf-entries-in-excel in the URL to get the same result.
—
How to Change the Download Slug
To configure this globally for all exports:
- Under the GravityKit menu, click on the Settings page
- Once inside, locate the GravityExport tab and click on the General Settings section
- Here you should locate the Download slug field
- Replace the default
gravityexportwith a custom slug, likereport,data, orexports - Please make sure to save the settings
> Example:
> Changing the slug to report will generate URLs like:
> example.com/report/0800fc577294c34e0b28ad2839435945
—
Slug Requirements and Restrictions
- Must be at least 3 characters long
- Cannot use reserved WordPress terms such as:
error ,Âm ,Âp ,Âpost_parent ,Âsubpost ,Âsubpost_id ,Âattachment ,Âattachment_id ,Âname ,Âstatic ,Âpagename ,Âpage_id ,Âsecond ,Âminute ,Âhour ,Âday ,Âmonthnum ,Âyear ,Âw ,Âcategory_name ,Âtag ,Âcat ,Âtag_id ,Âauthor ,Âauthor_name ,Âfeed ,Âtb ,Âpaged ,Âcomments_popup ,Âmeta_key ,Âmeta_value ,Âpreview ,Âs ,Âsentence ,Âfields ,Âmenu_order - Some plugin conflicts may also block certain words. If you get an error, please try using a different slug.
—
Filters
Additionally, you can programmatically change the default slug and allow multiple other slugs using the following filters:
gk/gravityexport/router/endpoints Modifies the list of download endpoints.
Example: add report and summary to the list of download slugs. So you can choose either one to be in your download URL.
“`php add_filter( ‘gk/gravityexport/router/endpoints’, function ( array $endpoints ) { $endpoints[] = ‘report’; $endpoints[] = ‘summary’;
return $endpoints;} ); “`
gk/gravityexport/router/default_endpoint Modifies the default slug.
Example: set report to be the default download slug.
php
add_filter( 'gk/gravityexport/router/default_endpoint', function ( string $slug ) {
return 'report';
} );
> Note: It is not possible to set a different default slug per form or feed ID.