WordPress.DB.PreparedSQL.NotPrepared

SQL query is not prepared

A database query includes dynamic data without using `$wpdb->prepare()` or an equivalent safe pattern.

critical weight

Why It Shows Up

The scan found a SQL string passed to `$wpdb` where variables appear to be interpolated or concatenated directly.

Why It Matters

Unprepared SQL can allow SQL injection when user-controlled values reach the query.

How to Fix

  • Move dynamic values into placeholders such as `%s`, `%d`, `%f`, or `%i` where supported.
  • Pass the values as separate arguments to `$wpdb->prepare()`.
  • For table names, column names, and sort directions, use strict allowlists instead of raw user input.

Affected Plugins

RankPluginScoreErrorsWarningsInstallsAddedUpdatedTop Issue
#1701Custom Fields for Gutenberg4224241k+Output is not escaped
#1702Delete Expired Transients4249655k+Direct Query
#1703Exclude Pages42311430k+Non Singular String Literal Domain
#1704Geo Blocker – Control Site Access by Region and IP421064900Direct Query
#1705Hide Cart Functions4212503k+Nonce verification recommended
#1706LeadSnap4214841k+Input is not validated
#1707Manage User Columns4215271k+Request data is not unslashed
#1708Mass Delete Unused Tags42219900Output is not escaped
#1709Republish Old Posts4283242k+Output is not escaped
#1710Secure Passkeys42146761k+Exception output is not escaped
#1711Sendcloud Shipping4278565k+Output is not escaped
#1712Set All First Images As Featured424413700Text Domain Mismatch
#1713Speed Contact Bar4253205k+Output is not escaped
#1714Transients Manager42455020k+Output is not escaped
#1715WC Price History4218214k+Database parameter is not escaped
#1716Auto Coupons for WooCommerce4281684k+Output is not escaped
#1717WP Author Security424013500Output is not escaped
#1718Eventin – Event Calendar, Event Registration, Tickets & Booking (AI Powered)422,5831,82310k+Text Domain Mismatch
#1719WP Fingerprint4234479k+Direct Query
#1720WP Mail Log42422910k+Text Domain Mismatch
#1721Auto Alt Text4352134k+Exception output is not escaped
#1722Customize Snapshots43942500Nonce verification recommended
#1723F4 Total Stock Value for WooCommerce4327121k+Output is not escaped
#1724Live Copy Paste for Elementor – Cross Domain Copy Paste & Page Duplicator4312327k+Request data is not unslashed
#1725Post title marquee scroll4343251k+Output is not escaped
#1726Qodax Checkout Manager – Checkout Field Editor for WooCommerce431727400Interpolated SQL is not prepared
#1727SQL Chart Builder431239600Non-prefixed global variable
#1728Term Management Tools4392610k+Non-prefixed hook name
#1729Terms Order WP – Categories And Taxonomies Order Plugin431247900Non-prefixed global variable
#1730Ultimate Member Widgets for Elementor – Login Form, Register Form & User Directory4315102400Non-prefixed namespace
#1731User Role Editor43117145700k+Output is not escaped
#1732WP Hotel Booking WPML Support431052400Direct Query
#1733Debug Bar Console442391k+Missing Arg Domain
#1734Github Embed4418351k+Non-prefixed global variable
#1735I Order Terms4440241k+Output is not escaped
#1736Back In Stock Notifier for WooCommerce | WooCommerce Waitlist Pro452611720k+Non-prefixed hook name
#1737Extended Post Status4527271k+Output is not escaped
#1738Inazo's flamingo automatically delete old messages4533204k+Output is not escaped
#1739Super Blank451315610k+Missing direct file access protection
#1740Display Featured Image for Genesis4664591k+Non-prefixed global variable
#1741Gravity Forms Constant Contact4636273k+Non-prefixed class
#1742Podcast Player – Your Podcasting Companion461413310k+Non-prefixed global variable
#1743SX User Name Security46429900Output is not escaped
#1744Delete Duplicate Posts4795010k+Direct Query
#1745DPO Pay for WooCommerce4728411k+Non Singular String Literal Text
#1746EasyFonts – Host Google Fonts Locally, Fast & Auto-Optimize, GDPR Compliant475581k+Interpolated SQL is not prepared
#1747Legal Pages – Privacy Policy, Terms & Conditions, GDPR, CCPA, and Cookie Notice Generator47448310k+Missing direct file access protection
#1748Log Emails4719296k+Non-prefixed global variable
#1749Userback4713202k+Output is not escaped
#1750Website Article Monetization By MageNet47172410k+Output is not escaped