Associate Vanity URLs with expiry date | Community
Skip to main content
Level 2
April 3, 2025
Solved

Associate Vanity URLs with expiry date

  • April 3, 2025
  • 2 replies
  • 659 views

Hello everyone, 

I have a requirement to associate the Vanity links to an expiry date. 
(i.e.) Say I have a Page A 
on the Vanity section am using the following vanity links 

/campaign/101-June-2025
/campaign/225-Dec-2025
/campaign/301-Jan-2026


When the Vanity expires, I should not only remove this entry on the page but also update the links/CTAs that point to the expired page with some other link. 


Can you please suggest how to achieve this ? Do let me know if there is an alternative ? 

Best answer by arunpatidar

Hi @harishdev 

I am not sure if there is any OOTB feature available.

But you can write a cron job that check those pages(configuration)-

  • search for the reference via using RefreshSearch 
  • remove the expired vanity from page
  • Update the link refresh
  • publish all the updated pages

2 replies

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
April 3, 2025

Hi @harishdev 

I am not sure if there is any OOTB feature available.

But you can write a cron job that check those pages(configuration)-

  • search for the reference via using RefreshSearch 
  • remove the expired vanity from page
  • Update the link refresh
  • publish all the updated pages
Arun Patidar
giuseppebaglio
Level 10
April 3, 2025

Because automatically changing website content is a sensitive operation, I suggest, in addition to Arun's suggestion, that editors manually verify algorithmic changes before publication. This preview would allow editors to review the algorithm's output.

kautuk_sahni
Community Manager
Community Manager
April 15, 2025

@harishdev Did you find the suggestions helpful? If you need more information, please let us know. If a response resolved your issue, kindly mark it as correct to help others in the future. Alternatively, if you discovered a solution on your own, we'd appreciate it if you could share it with the community. Thank you!

Kautuk Sahni