68% seo-by-rank-math

Code Review | Rank Math SEO

WordPress plugin Rank Math SEO scored68%from 54 tests.

About plugin

  • Plugin page: seo-by-rank-math
  • Plugin version: 1.0.207
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Nov 19, 2018
  • Latest release: Nov 30, 2023
  • Number of updates: 510
  • Update frequency: every 3.8 days
  • Top authors: rankmath (89.61%)MyThemeShop (10.59%)

Code review

54 tests

User reviews

6178 reviews

Install metrics

2,000,000+ active /78,136,504 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲2.55MB] [CPU: ▲14.64ms] Passed 4 tests

Analyzing server-side resources used by Rank Math SEO
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /6.01 ▲2.5555.46 ▲3.25
Dashboard /wp-admin5.91 ▲2.5672.50 ▲10.17
Posts /wp-admin/edit.php5.96 ▲2.6071.88 ▲27.17
Add New Post /wp-admin/post-new.php8.43 ▲2.54112.40 ▲19.81
Media Library /wp-admin/upload.php5.76 ▲2.5360.69 ▲25.34
Scheduled Actions /wp-admin/tools.php?page=action-scheduler5.9469.28

Server storage [IO: ▲8.11MB] [DB: ▲0.02MB] Passed 3 tests

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 850 new files
Database: 6 new tables, 20 new options
New tables
wp_actionscheduler_groups
wp_actionscheduler_actions
wp_actionscheduler_claims
wp_actionscheduler_logs
wp_rank_math_internal_meta
wp_rank_math_internal_links
New WordPress options
rank_math_modules
rank_math_version
rank_math_known_post_types
rank-math-options-sitemap
widget_recent-posts
rank-math-options-titles
action_scheduler_hybrid_store_demarkation
rank_math_notifications
rank_math_install_date
db_upgraded
...

Browser metrics Passed 4 tests

An overview of browser requirements for Rank Math SEO
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,813 ▲6614.03 ▼0.221.56 ▼0.5641.24 ▼6.55
Dashboard /wp-admin2,221 ▲435.64 ▼0.0894.57 ▼18.8442.68 ▼3.43
Posts /wp-admin/edit.php2,123 ▲231.98 ▲0.0340.24 ▲3.1735.69 ▼3.71
Add New Post /wp-admin/post-new.php1,545 ▲1923.39 ▲0.41638.58 ▼15.8769.12 ▲12.17
Media Library /wp-admin/upload.php1,420 ▲204.21 ▼0.0297.18 ▲0.6541.02 ▼1.68
Scheduled Actions /wp-admin/tools.php?page=action-scheduler1,2501.8230.0631.54

Uninstaller [IO: ▲0.00MB] [DB: ▲0.02MB] 50% from 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Zombie tables detected upon uninstall: 6 tables
    • wp_actionscheduler_actions
    • wp_actionscheduler_logs
    • wp_actionscheduler_claims
    • wp_actionscheduler_groups
    • wp_rank_math_internal_meta
    • wp_rank_math_internal_links
  • The uninstall procedure has failed, leaving 21 options in the database
    • rank-math-options-instant-indexing
    • action_scheduler_migration_status
    • rank_math_install_date
    • rank_math_version
    • can_compress_scripts
    • widget_recent-posts
    • rank-math-options-general
    • widget_theysaidso_widget
    • rank_math_db_version
    • rank_math_known_post_types
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/seo-by-rank-math/assets/vendor/schema/schema-map.php
  • 97× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Warning
      require(wp-content/plugins/seo-by-rank-math/vendor/donatj/phpuseragentparser/.helpers/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/seo-by-rank-math/vendor/donatj/phpuseragentparser/.helpers/constants.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/seo-by-rank-math/vendor/cmb2/cmb2/includes/types/CMB2_Type_Taxonomy_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Textarea' not found in wp-content/plugins/seo-by-rank-math/vendor/cmb2/cmb2/includes/types/CMB2_Type_Wysiwyg.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'ActionScheduler_Abstract_QueueRunner' not found in wp-content/plugins/seo-by-rank-math/vendor/woocommerce/action-scheduler/classes/WP_CLI/ActionScheduler_WPCLI_QueueRunner.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/seo-by-rank-math/vendor/cmb2/cmb2/includes/helper-functions.php:131
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/seo-by-rank-math/vendor/woocommerce/action-scheduler/classes/abstracts/ActionScheduler_Abstract_ListTable.php on line 4
    • > PHP Fatal error
      Uncaught Error: Class 'CronExpression_AbstractField' not found in wp-content/plugins/seo-by-rank-math/vendor/woocommerce/action-scheduler/lib/cron-expression/CronExpression_MonthField.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'CronExpression_AbstractField' not found in wp-content/plugins/seo-by-rank-math/vendor/woocommerce/action-scheduler/lib/cron-expression/CronExpression_DayOfMonthField.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'CronExpression_AbstractField' not found in wp-content/plugins/seo-by-rank-math/vendor/woocommerce/action-scheduler/lib/cron-expression/CronExpression_DayOfWeekField.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_File_Base' not found in wp-content/plugins/seo-by-rank-math/vendor/cmb2/cmb2/includes/types/CMB2_Type_File.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: wordpress seo, redirection, sitemap, schema, seo...

seo-by-rank-math/rank-math.php 77% from 13 tests

"Rank Math SEO" version 1.0.207's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("seo-by-rank-math.php" instead of "rank-math.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 149 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected72,779 lines of code in 782 files:
LanguageFilesBlank linesComment linesLines of code
PHP65916,79440,02567,420
CSS431857032,848
JavaScript622993151,659
JSON400364
XML31716199
SVG500109
YAML113080
Sass29153
make27029
Markdown14018

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity18.16
▷ Minimum class complexity1.00
▷ Maximum class complexity188.00
Average method complexity2.98
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces51
Interfaces12
Traits32
Classes456
▷ Abstract classes306.58%
▷ Concrete classes42693.42%
▷ Final classes10.23%
Methods4,350
▷ Static methods71316.39%
▷ Public methods3,05270.16%
▷ Protected methods4049.29%
▷ Private methods89420.55%
Functions175
▷ Named functions11968.00%
▷ Anonymous functions5632.00%
Constants162
▷ Global constants74.32%
▷ Class constants15595.68%
▷ Public constants155100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
5 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/admin/img/icon-gif.png3.22KB3.61KB0.00%
assets/admin/img/score-100.png16.74KB9.48KB▼ 43.38%
assets/admin/img/icon-play.png4.58KB4.29KB▼ 6.38%
includes/modules/analytics/assets/img/report-logo.png6.42KB6.97KB0.00%
includes/modules/analytics/assets/img/report-icon-external.png2.47KB0.60KB▼ 75.81%