The latest episode of the Accessibility Checker Changelog livestream was hosted by CTO Steve Jones and lead developer William Patton. This biweekly series offers a behind-the-scenes look at the newest Accessibility Checker WordPress plugin update, including recent features, development decisions, and insights into the broader WordPress accessibility landscape.
In this livestream, we explored how developers and site managers can bring accessibility auditing out of the WordPress dashboard and into the terminal.
This episode focuses on the powerful WP-CLI commands now available in Accessibility Checker (Free v1.15.0 and above), demonstrating how they can accelerate workflows, integrate with automation, and provide deeper insight into your site’s accessibility health.
Watch the Video
Video Transcript
Show/Hide Transcript
Steve: All right. Am I live?
Yeah, so we were having some technical difficulties with Restream. It sounds like I’m live now on YouTube. I just gotta get William over here with me and we can start real quick. Sorry for the delay with the technical difficulties.[00:01:00]
But it looks like we are live. Okay.
Yeah. So, let’s see.
There we go. There’s William. Let’s get him in here. Join the party.
William: We’re live.
Steve: We’re live. That was quite the undertaking. But, it looks like we’re only on YouTube, which I think is fine. Let’s see if I can update channels, pair of channels, your channels.[00:02:00]
Mm.
SteveJonesDev on X. Doesn’t that sound cool?
William: Maybe
Steve: You said maybe
William: Can’t say no.
Steve: Again, welcome William. Last time we were talking and we were streaming to nobody, so welcome to the Accessibility Checker Changelog livestream.
William: Remember when I said hi to everyone.
Steve: Hi to everyone that wasn’t there.
William: Yep.
Steve: I set this to go out to X. Maybe it’s working, I’m not sure, but, maybe not. Cool. Looks like we’re live.
All right.
Lemme post.
Post that one.[00:03:00]
All right, so let’s try to…
Today we are talking about the CLI. This episode is kind of generically named From Dashboard to Terminal Accessibility Checker: CLI in Action. Which is fine, but, when we were discussing this, Chris Hinds, our COO, he was like, we’re thinking of names, he said, pretty fly for ACL. Which I thought was just awesome for, being a kid that grew up in the nineties.
So if you’re not old, you might not get that reference, but this is
William: I guess I’m old.
Steve: You’re old. You don’t get the reference.
William: No, I get it. I’m old.
Steve: You are old. Yeah. Okay. I didn’t know it could be an American thing too, like, how big is…
William: Everyone knows Offspring.
Steve: The Offspring, yeah.
Let me get your screen set up, William.[00:04:00]
And then, we will plow through this and we still want to end at a good time and not take up too much time. So, let’s jump into it.
William: Yep.
Steve: This is the Changelog live stream where we talk about the Accessibility Checker, which is a WordPress plugin that helps you make your website accessible and stay accessible.
So, a whole suite of plugins.
The Accessibility Checker free plugin, which you can get on WordPress.org, the Accessibility Checker Pro plugin, which you can find at EqualizeDigital.com/AccessibilityChecker.
And we have a few add-ons. We have Audit History Add-on, a Multi-site Add-on, and an Export Add-on that are all included at different levels of the pro plugin.
Today we’re talking about the CLI.
William, for those that don’t know, can you give us a brief rundown on what the WPCLI is?
William: Yeah, so WordPress, [00:05:00] CLI or WPCLI is basically a terminal software that allows you to run various commands specifically for WordPress.
The way it works is it boots up all of WordPress so that any commands that you’re running are running the same way your site would be if you were just visiting the site. For an example. I can just run this WP Command here.
Steve: Would you like me to pull up a screen?
William: Yeah.
Steve: What I’ve just pulled up Williams screen, and on his screen you can see he’s got it split in two. On one side he’s got just a WordPress install in the admin, and on the other side he’s got a command line terminal up.
What did you type in?
William: Yes, I just typed in WP generically and in my local, I need to type, allow root because I’m running this as a root user. But, in a terminal, which is a [00:06:00] terminal running on the server that this site in the left hand side is running. So, the site I have in my browser, I have the server terminal open on the right hand side, and if I just take WP generically and allow root for the fact that I’ve logged in with a root user when I shouldn’t really do that.
Steve: Mm-hmm.
William: Up pops a whole bunch of information about that WP command as is. It contains the description, manage WordPress through the command line, a synopsis, which WP command telling you how to use commands.
Then it lists all the various different commands that are available, such as like you can manage widgets so there’s a widget command. Roles, so there’s a role command. Eval, which allows you to just genetically run arbitrary PHP code.
Steve: Mm-hmm. So, like installing and uninstalling plugins, that’s probably the [00:07:00] most used command, right?
William: There is a plugin command. You manage your plugins and, let’s just run that or test it.
WP plugin list.
It’ll provide a very long and various list of plugins on this website.
Steve: While that’s running, how does a user get the WPCLI? So, if your host, if you have SAH access… most managed WordPress host these days, do provide the WPCLI. And, if you’re running an application like Local by Flywheel app. If you’re running a site, you can right click on the site and open site shell and that are automatically open your terminal window and have the WPCLI running.
William: Yeah. If you are running just a website that does not contain WPCLI out the box from the host, you can go ahead and [00:08:00] install it yourself. It is just an executable PHP file. I’ll pull up the website and we’ll look at the genetic instructions. It is really straightforward to just install this anywhere.
Steve: Mm-hmm.
William: What I did here was I ran WP plugin list and it produces this table of all the plugins that are on this website, which on this website is probably around 50 various plugins. Also provides a status, so we have a name, Accessibility Checker, a status of active, and an update of none, that there is no update available from .org right now. I’m running the latest version, which is 1.33.0, and it tells you that right in the chart. If there was an update available, it would tell me that version, and it says whether auto updates are enabled and on this test site it isn’t.
Steve: If there was an update available, you could initiate the [00:09:00] update right from the command line?
William: Correct.
If we get the help for WP Plugin help, it lists all the various sub commands. You can activate a plugin, you can manage the all updates, you deactivate, delete.
You can get details which will basically just pull up what appears as the file header. The information that you see in the plugin description in the dashboard if you’re looking at the plugins page in the backend. So install, check whether it’s active. You can check whether plugins are actually installed, so you can build automations with WPCLI.
If a specific plugin is installed, do one thing. If it’s not, do another.
You can list them like I just done. Find the path and search the WordPress.org repository and get the status of any [00:10:00] one or all the plugins on your site. You toggle them, which will either activate or deactivate depending on what the initial state is. Uninstall, update, and you can verify the check sums.
Some systems will automatically verify the check sums when you download the plugin, but if not, you can ve verify the check sum of the plugins files against the org’s check sums, which will allow you to verify whether the files have been changed or not.
This is quite useful if someone has a website that maybe has been hacked or you wanna verify that none of the files of a specific plugin have changed.
Steve: Yeah, that’s a lot of power. At the right, at your fingertips.
William: Yes and this is just one of a great many commands.
Steve: Another one that we use a lot is a Search and Replace. You can search for, like if you migrate a site, you can search for the old URL and you can put in the new URL and run a Search and Replace. You can run that in a sandbox mode so you can see what it’s going to do. [00:11:00] That allows you to do this without installing a plugin and a plugin that’s gonna run inside of, WordPress and maybe have some performance issues. You might have better luck and better speed running this from the server level with the CLI.
William’s typing in WP Search.
William: Yeah, so I’ve done Search Replace all over and this has pulled up the usage. It shows exactly what the format of WP Search Replace command would be, and the basics is WP space, search-replace space, and then the old term that you’re looking for, space, the new term.
That’s the simplest way you can use this command, but there is a lot of different flags or options you can pass, like dry run the table. You can run a dry run.
Steve: Yeah.
William: If you’re in a network, a WordPress multi site, you can tell it that. You can also pick an individual site if you are. You can tell to skip [00:12:00] various tables, skip columns in tables, so it’s very powerful.
Steve: Yeah.
William: You can also tell it to do recurse objects, which will handle serialized options, which is incredibly useful when a plugin store their data in an encrypted or a serialized array, which is common and generally how you should do it. But this handles that.
Steve: That’s all great. That’s a lot of power.
It does a lot.
But what does that mean for Accessibility Checker?
William: for Accessibility Checker, you can create custom commands, and we have a few common things in our plugin that people would generally be doing.
They might be wanting to check how many issues a specific post has, they might disagree and wanna delete the issues and start fresh.
They might wanna actually find some information about the entirety of their website or the situation with that as,
Steve: Yeah.
William: You can create [00:13:00] custom commands that do whatever you might like on a website.
Steve: We have a set of a handful of them. And before we run through each one,
William: Correct.
Steve: We’re gonna go through individual.
Why did we decide to create custom CLI commands? We just showed the power of it, but was it for our own use? Was it for a client’s use? Was it requested?
William: Initially, it was for me. I wanted to be able to delete issues, to check the status of issues without having to open individual posts. I wanted to be able to do these things, which was the origin of me deciding I might create these.
However, we did get web posts ask us specifically for these commands so that they could potentially integrate with dashboards they have for their customers to provide some additional insight from the top level of a website.
This here is just a genetic WordPress website. We have the plugin installed Accessibility Checker. If I [00:14:00] hover over the menu item in the left and I click Accessibility Checker, it is gonna load up our page and it contains various statistics. It might be nice to show these statistics elsewhere.
Steve: Mm-hmm.
William: That will be something I will demo.
Steve: Cool. Our CLI commands were introduced in version 1.15.0 so it’s been quite a while that we’ve had these for several years and we’ve just been iterating and adding a few along the way, and I think it’s built some momentum and there’s several others that we will be implementing moving on.
Let’s run through the list, William, and let’s go through each one.
Starting with, do you wanna show how you can list out what our commands are?
William: Yes.
In WP-CLI you can list out all of the commands.
If you type WP space and then whatever the command is, in our case it is Accessibility Checker, the name of our plugin that is considered the namespace. [00:15:00] And if we just type those into the CLI, it will provide some synopsis or some generalized help, which effectively lists out all of the commands available under this namespace averse.
Steve: Mm-hmm.
William: Currently, we have four commands on this site and it lists the various flags and the order that it is expected in.
WP Accessibility Checker returns four commands that can be outlined. There is the cleanup orphaned issues command, delete stats, get site stats and get stats.
The way you would run each of them is you would type WP space, accessibility-checker space, and then you would type in the name of the command.
Steve: I noticed you’re missing one.
William: I am missing one here in this thing for the purposes of demoing.
Steve: Okay.
William: I decided not to have it [00:16:00] enabled by default.
Steve: We had a little internal thing too where typing accessibility-checker is quite time consuming. Believe it or not, as many times as I’ve tied Accessibility Checker it never gets easier to spell it right or to get the letters in the right order.
We have a prefix for Accessibility Checker. It’s called edac and internally we use that a lot. It’s just EDAC, Equalize Digital Accessibility Checker.
I wanted that and William wanted it inside of the CLI as well. William’s gone through and actually added that as an optional handle for all of our CLI commands, correct?
William: Correct.
If you were to type WP space edac space or press return at that point, those same four commands that previously appeared to clean up orphan issues, delete stats, get site stats and get stats, they all appear as well.
There is two ways that you can [00:17:00] invoke these commands. I chose not to only support the shorthand version because people might expect the full plugin name as the command name. Feels like I would expect that.
Steve: Yeah.
William: But it is much easier to type just four letters
Steve: edac.
William: With the shorthand version.
Steve: Let’s run through ’em.
Do you wanna run through ’em in the order? You have ’em there or do you want to do ’em in the order we have it in the notes.
William: Let’s do it backwards from the order I have on here.
Steve: Okay, so that would mean get stats is first.
William: Get stats Is the first one. Okay.
In my left panel, I have the WordPress Post list open and I’m just hovering over one of the Posts so that I can see the URL in the lower part of the browser.
I can see that the ID of this Post is 2080. I need to remember that because this command requires a Post ID to type [00:18:00] in.
This post here, I’ll click on the name and I’ll open it and we can see the results here. It is 93% of the tests are passed on this Post. There is one error and four warnings. If I come back to the terminal and I type in WP Space, edac space, get-stats, and then that Post ID, which was 2080.
Steve: Yeah. Williams’ local setup, he requires the allow root flag. When I run this from like the local app or from WPEngine CLI, or SSH, the CLI through WP Engine, I don’t typically have to put that flag in.
William: Yeah. Using root to run these commands is not recommended for the sake of ease, because this is my local server I can access the root user, usually you will not have access to the root user, so I [00:19:00] have to type -allow-root for all of these commands. Most users would not.
I did type wp edac get-status 2080, which is the ID for this test Post and as I said earlier, 93% of tests were passed shown in the WordPress backend editor. We can see that reflected in the result that gets returned from the command. So, passed tests 93, one error, one warning, zero ignored items, zero contrast errors. The content grade is currently zero because it actually doesn’t have enough content to analyze so the readability is also NA and the simplified summary is false, and it’s N\/A, because that is escaped and it is escaped on purpose because this could be consumed by machines, and we would like to make [00:20:00] sure that we do not break any of the expectations of a machine.
All of this data that appears in the command line is also available in the WordPress backend dashboard for this command, so we can see exactly the same numbers on both sides.
Steve: Very cool. That is an awesome way to end the command line to get the stats for a single post.
William: And if you were to want just a single stat so you stats equals, and then let’s just say we only care about errors, you can run that command.
Steve: It’s errors with an S.
William: Yes. stat errors and it returns just the stat that you have requested.
If you wanted to fill with this, you can.
Steve: Mm-hmm.
William: It isn’t super important for a short piece of data, but you will see later on we do expose a lot of data on some of these commands.
Steve: Cool. The next [00:21:00] one is get site stats.
William: Yes.
Steve: These are the site level stats that you showed earlier, right?
William: Correct.
If I type in that as a command, wp space edac get-site-stats and my allow root flag. We can see that output a lot of different pieces of data. Some of these appear directly on this stats, the welcome page or the stats page for Accessibility Checker Pro. But, some of them don’t necessarily appear on this page, so we might get slightly more information from the command line.
Steve: Yeah, so can I add some clarity there? These stats that are being output. So the command line is showing a whole slew of site level stats about the accessibility scanning that has [00:22:00] been done on the site. These stats are not available in the free plugin via the dashboard, but they are available in the free plugin via the CLI.
William: Correct.
I do have the pro plugin installed on this website right now. I have access to this stats dashboard, but if we only had the free plugin, these numbers would not be here. I can see that across this entire test site, 13.95% of the tests are passed, which means most of the tests have failed on this test site, which is expected for such a bad test site. But, in the free plugin, you wouldn’t be able to get that number here.
Steve: Unless you ran a CLI command.
William: But you can’t get that number from the WPCLI command.
Steve: That’s a little nugget on how to get a little bit more out of the free plugin.
We don’t need to run through what each of these stats are, but this is, how many is this, William? Like 30 stats?
William: It’s about [00:23:00] 30 ish stats. However, if I run the help command, which you can do on the WPCLI by typing //help after the command. It will…
Steve: Your allow root flag. Yeah.
William: Maybe I should have restarted this server as well. ’cause it was particularly slow.
Maybe I can’t touch the, on the server.
Steve: Yeah. Timeout. That’s cool.
In the means of time, you can you show us how to pull one of those stats with a flag?
William: I’m gonna just copy this rule scan one for example, so, we have 43 individual rules currently on this test site. There may be more or less than that in the actual plugin.
If we have the exact same command, so wp edac [00:24:00] get-site-stats and you can do –stats= and paste the name of a stat, which you know, I’m just doing rule_count. For this one it is –stat and it will input just the individual rule.
So, I see 43 rules and success message, but none of the other stats right now after typing –stats=rule_count.
Steve: In this case, pulling out one stat actually is beneficial because it’s a huge array of stats and if you were using CLI to grab this information and combine it with something else, you could just get what you wanted and not have to pull that big, huge array every time.
That’s the site stats. Anything else on that? I think that’s it.
William: That’s it? Yep.
Steve: In relation to that we have delete stats.
William: Correct.
[00:25:00] If we take that exact same test Post I had open a minute ago. It’s just called test and looking at a WordPress Post list in the backend. Because I have the Pro Plugin installed, I have visual indicators on every individual Post showing how many issues each one has.
This test Post has one error, zero contrast errors, and four warnings as we saw previously in the back end and also from the stats and it’s Post ID it is still 2080.
If I were to run wp edac delete-stats, press return.
Steve: Oh, you gotta put the ID in, right?
William: Yes. So, it does actually enter and says, no Post ID provided. Let me just pick a random number, like 111 as a Post ID. It also says Post ID 111 does not [00:26:00] exist. And that’s true. On this test site, all of my Post IDs are in the four digits at this point.
The correct ID for this specific Post that I just had open was 2080, and I have a success message now after running that, that says stats of 2080 deleted.
If I were to refresh the page and the actual backend of the website. I can now see that the test Post has gray icons for each of the accessibility errors, contrast, warnings and ignored items because that ID actual has no more data anymore. I’ve deleted those stats.
But, if I were to open the Edit Panel for this Page again, it will instantly rerun the scan. It found different issues now because I have some ignored items. But it’s still, one error and four warning still, but three of them are now ignored because I had to ignored previously said.
Steve: Cool.
William: And that’s [00:27:00] 95% now passed with ignored items.
Steve: I think part of that delete command that, at least from some of our dev stuff and some unique edge cases where we were running into orphaned issues like orphaned Accessibility Checker issues in the database when a Post was like maybe migrated from one Post Type to another, and we’ve actually surfaced that command. You could actually clear issues from the Edit Screen and from the Front-end Highlighter. You can do that now instead of, whereas before you had to do it through the CLI.
That does lead us to, we do have a command related to our cleanup process that we have now, right?
William: Correct.
We have a cleanup process that runs once a day and it will delete up to, I think, 20 posts in the backend if they have become orphaned.
That does happen if someone changes the Post Type of a Post or maybe the plugin had been deactivated for some time, Posts had been deleted and then it was reactivated, orhan Posts [00:28:00] can appear and it will run once a day and try and clean them out.
Steve: It runs once a day via the CRON.
William: That’s how it works in the actual website.
However, if that isn’t quick enough for you and you have access to WPCLI, you actually can run that command from the WPCLI, and you can provide a batch size of whatever size you like, and you can also give it a sleep time, which is referenced in seconds, which prevents your server from being overloaded if you’re gonna delete an awful lot of orphan data.
The command is wp edac cleanup-orphaned-issues, and if you just press return on that command “No orphan issues found” on this testing because…
Steve: Mm-hmm. [00:29:00]
William: I’ve run this many times.
Steve: Yeah. If you were working on redoing a website that already had a bunch of accessibility scans and you were actually like say moving Posts from one Post Type to another.
Say you have a press releases Custom Post Type, and you want to actually just move those back over into Posts. You can run whatever plugin you’re using to migrate them, the Custom Post Type, and then you could run this command and they’ll actually find those orphaned Accessibility Checker issues and delete ’em from the database. And what it does is it just, it’s a cleanliness thing and it’s just the plugin having good hygiene. But, there definitely are those cases where you can do it before the command, the CRON job runs, so you can have ’em all cleaned up right away and then run a re-scan and you have all accurate accessibility stats.
William: Yeah, and if you were using, so if you’re using a plugin to move Post Types, then this command might actually be very useful for you.
But, if you’re manually moving those Post Types yourself, [00:30:00] you might also manually move the issues.
However, none of the existing tools that move Posts between Post Types are going to understand that our tables are there and have to do that, so this command exists.
Steve: Yeah.
William: Because that is the case, right? None of the tools that exist for moving things between Post Types or doing anything weird to Posts that may cause a desync are going to understand to clean up these tables. So, we now clean up these tables ourself and as a convenience, we also provide the CLI command.
If you move 10,000 Posts, you can clean those 10,000 Posts metadata up instantly, and cleaning up this data does actually make the SQL queries faster. If you clean up a lot of data, it’s gonna make the queries a lot faster.
Steve: Yeah. Cool. Like we said, the plugin has its own hygiene process.
It goes through every day and cleans its stuff up. But, if you find a need to that you wanna work fast, you can actually use the CLI [00:31:00] to expedite those cleanup processes.
That leads us to the last one, William. Do we want to talk about it?
William: Sure. Do you want to talk about it while I try and install it on this testing?
Steve: The last one, so one we’ve recently added was the, we have a license command. When you buy the pro plugin, you get a license key and you can take that license key and you can go to the settings panel, add the license key and activate it. It’s your typical Premium Plugin License Key process.
But, we’ve had some requests recently from some partnerships that we’re working through with some hosting companies that they want to be able to service the getting the license key and executing the license key on their server for their customers.
So, we added a CLI command that will actually let you activate and deactivate the license key. I think you can do an activation check as well, William?
William: You can [00:32:00] check the status of the key.
Steve: Yeah.
William: We could probably show that one first. wp edac license –action=, and then you can give it an action. There’s three options, it is either activate, deactivate, or status.
Steve: If you wanna put an actual key in there, I can switch the screens so that we don’t broadcast our…
William: Yeah, I can drag it off to another screen while I do that. As you can see right now, currently the status of the license on this website is currently valid and, pulling it partly over the screen, I’m showing in the back end of this website, we can actually see the active flagged on the license page. I’m gonna copy that license. I’m going to type wp [00:33:00] edac license –action=.
If I could spell it, action=deactivate, and I’m gonna pull this off the screen just for a second to make sure that it doesn’t list the key.
I don’t think that deactivate does list the key. It doesn’t, so it focus back over. We have a success message and it says license deactivated successfully.
Steve: You can show that on the page if you just drag it over slightly.
William: Yes. I have this key here if I’ve, I’m gonna reload the page and it now says to enter your license key in the license page on the back end because there is no license key. It has been [00:34:00] deactivated, which means it’s been cleared from the back end.
If I go to type wp edac license –action=activate –=, and I’m going to drag this off the screen again for a second and paste in a key and press return. I get a message that says, license activated successfully.
Lemme see if I can resize this screen so that I can drag that over and show you.
I run the command and I get success license activated successfully, and as I pulled this partially [00:35:00] across the screen again and reload the page. Now, we can see active on the license tab. I’m gonna just delete that and pull this right onto the screen so you can see. It now says active, where previously it said, please enter your license key.
I’ve deleted this for now.
If I click this deactivate button, it does exactly the same thing as running the deactivate command.
Steve: Mm-hmm.
Those are a lot of our WPCLI actions. We have a lot more that we’re looking at adding. Specifically, even some relating to be able to actually pull a list of all the issues on a page and many other things as well as a full issues API that we’ve been working on for some time bringing that over.
Do you have anything else to add before we close this up?
William: I guess one other thing. We do have documentation on our GitHub repo of all of the commands with examples of running them and output [00:36:00] from each of the commands. I will be updating this today with the license command.
Steve: Right.
William: Yeah.
Steve: We do have this on EqualizeDigital.com/AccessibilityChecker/documentation as well.
You can find it in both places, either on the Accessibility Checker Free Plugin repo, or on EqualizeDigital.com.
This is great.
This kind of opens the door bringing the CLI and bringing Accessibility Checker via the CLI into being able to integrate it into lots of different things, into even your CI pipeline, things like that, and any kind of automation that programmers can dream up.
You can utilize this to integrate Accessibility Checker with your applications.
William: Correct.
I think the first thing I’m looking forward to seeing is getting it into people’s dashboards, like, from various site management systems, like GoDaddy has one, there’s, WP, there’s a whole bunch of WordPress management [00:37:00] softwares that can effectively now pull this data right into that dashboard.
Steve: Alright, thanks William. Thanks for sharing that. That was a quick rundown on the CLI, we’re capped for time here, but please check out Accessibility Checker.
Please go to WordPress.org.
Give us a five star review if you like to plugin and use it.
Download the free plugin.
Give us your feedback and we look forward to joining you here in two weeks For the next Accessibility Checker Changelog.
Take care. Thanks, William.
William: Thanks. See you.
What is WP-CLI and Why It Matters
WP-CLI (WordPress Command Line Interface) is a terminal tool that enables you to manage your WordPress site without needing to access the dashboard.
“WP-CLI is basically a terminal software that allows you to run various commands specifically for WordPress. The way it works is it boots up all of WordPress so that any commands that you’re running are running the same way your site would be if you were just visiting the site.”
William Patton, Senior Plugin Developer
With WP-CLI, you can install and update plugins, manage users, run search-and-replace operations, and even execute arbitrary PHP code. It’s a powerful way to perform batch operations, automate repetitive tasks, and manage large-scale sites efficiently.
CLI Support in Accessibility Checker
We’ve embraced WP-CLI by introducing a suite of commands that make it easier to manage accessibility data programmatically. Accessibility Checker Free v1.15.0 introduced three core WP-CLI commands for fetching, managing, and deleting accessibility scan data.
“Typing ‘accessibility-checker’ is quite time consuming. Believe it or not, as many times as I’ve typed Accessibility Checker, it never gets easier to spell it right. That’s why we added
Steve Jones, Chief Technology Officeredac—short for Equalize Digital Accessibility Checker—as a quicker namespace. All commands can be run with eitherwp accessibility-checkerorwp edac.
We also added a cleanup command to clear orphaned issues, license key management for Pro users, command filters for more targeted queries, and a shorthand alias for quicker typing.
Get Stats for Individual Posts
The get-stats command allows you to fetch accessibility statistics for a specific post or page by post ID.
During the livestream, William demoed this by running wp edac get-stats 2080, which returned a JSON object showing passed tests, errors, warnings, ignored items, contrast errors, readability scores, and whether simplified summaries were enabled. The output mirrors what you see in the WordPress dashboard.
All the data that appears in the command line is also available in the WordPress backend dashboard for this command, allowing us to see exactly the same numbers on both sides.
You can also use the --stat= flag to return only specific data points, like errors, if you’re integrating results into external tools or scripts.
Get Site-Wide Stats
The get-site-stats command provides an overview of accessibility data across the entire site. This returns approximately thirty different statistics, many of which aren’t visible in the free plugin’s dashboard but are available through the CLI, even without a Pro license.
You can use the --stat= flag to focus on specific metrics, which is especially useful when automating reports or integrating site-wide data into custom dashboards.
Delete Stored Stats
When you need to clear out stored accessibility data for a specific post—for example, after significant content changes or debugging—you can use the delete-stats command. William demoed this by running the command on a test post, receiving a success message, and then refreshing the page to see the icons reset.
After running this command, the test post displays gray icons for accessibility errors, contrast, warnings, and ignored items because that ID no longer has any stored data. Opening the post again triggers a fresh scan, regenerating its stats.
Clean Up Orphaned Issues
Accessibility Checker includes a daily CRON job that automatically cleans up orphaned issues—data left behind when posts are deleted or changed between post types. If you want to run this cleanup manually or on your own schedule, you can use the cleanup-orphaned-issues command. You can specify a batch size and sleep time to control performance when working with large datasets.
Cleaning up this data actually makes the SQL queries faster.
Manage Licenses from the Command Line
For Pro users, we’ve added a license command that lets you activate, deactivate, or check license keys directly from the terminal. This is especially useful for agencies, hosts, and developers managing multiple environments.
1. Check License Status
wp edac license –action=statusThis command checks whether the current license key on the site is active and valid. William ran this first to show that the license was active before deactivating it.
2. Deactivate a License
wp edac license –action=deactivateThis command deactivates the current license key stored in the site. After running it, William refreshed the page and showed that the license key had been cleared from the backend.
3. Activate a License
wp edac license –action=activate –key=This command activates a new license key directly from the terminal.
Clear Cached Data for Accurate Results
Several of these commands support a --clear-cache flag, which forces fresh data retrieval after site updates or content changes. This ensures your stats reflect the latest scans, which is especially valuable in CI/CD pipelines and automated scripts.
How Developers Can Use These CLI Commands
These CLI commands open up a range of possibilities for developers, agencies, and accessibility professionals. You can integrate accessibility checks into CI/CD pipelines, automate audits across hundreds of posts or entire sites, query or delete stats quickly during development, and manage licenses programmatically without logging in. It’s a flexible, powerful way to extend Accessibility Checker beyond the dashboard.
What’s Next for Accessibility Checker CLI Commands
We are planning several upcoming features for the CLI, including commands to retrieve detailed issue lists for posts and a comprehensive Issues API.
Get Started with Accessibility Checker CLI Commands
WP-CLI commands are available in Accessibility Checker Free and the Pro version. To try them out, make sure WP-CLI is installed on your server or local environment, then run any of the supported commands using either the full accessibility-checker namespace or the shorthand edac.
All commands are documented in the Accessibility Checker GitHub repository and on our Accessibility Checker Documentation. These resources include examples, available flags, and expected outputs to help you integrate CLI commands into your workflow.
If you’re automating audits, managing multiple sites, or prefer working in the terminal, these commands give you more flexibility and speed than ever before. Update to the latest version to start using Accessibility Checker CLI commands today.
Join Us for the Next Livestream
The Accessibility Checker Changelog livestream airs biweekly, alternating with our plugin release schedule. Each episode will feature demos, technical deep dives, and previews of new features. Follow us on YouTube to get notified when we go live.
To learn more, download the plugin, or upgrade to Pro, visit our Accessibility Checker page.
If you have feedback or questions, connect with us on X:
- Steve Jones: @SteveJonesDev
- Equalize Digital: @EqualizeDigital
We look forward to sharing more soon. See you at the next changelog update.