|
/ Documentation /Developers Documentation/ Customize Maximum SEO Title Length surerank_title_length

Customize Maximum SEO Title Length surerank_title_length

Hook: surerank_title_length

Description: This filter allows you to customize the maximum character limit for SEO titles generated by the SureRank plugin. By default, SureRank sets a predefined length for titles to maintain optimal display in search engines. You can use this filter to increase or decrease that limit based on your preferences.

Source: inc/functions/defaults.php

Usage: Adjust the SEO title length to better suit your content strategy or branding guidelines.

Example:

PHP
// Filter to change the maximum length of the SEO title in SureRank
add_filter( 'surerank_title_length', function() {
    return 60; // Set max title length to 60 characters
});

You can add the example code to your child theme’s functions.php file or use a plugin like Code Snippets to safely insert custom code. Using a code snippet plugin is recommended for easier management and to ensure the code remains active even if you switch themes.

Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
On this page
Scroll to Top