{"id":90,"date":"2026-10-22T09:00:00","date_gmt":"2026-10-22T09:00:00","guid":{"rendered":"https:\/\/cus.dualcube.com\/mvx1\/wordpress-conditional-logic-form\/"},"modified":"2026-10-22T09:00:00","modified_gmt":"2026-10-22T09:00:00","slug":"wordpress-conditional-logic-form","status":"publish","type":"post","link":"https:\/\/cus.dualcube.com\/mvx1\/wordpress-conditional-logic-form\/","title":{"rendered":"WordPress conditional logic forms: how to show the right fields to the right people"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Conditional logic means a form changes based on what someone has already told it. Choose \u201cOther\u201d from a dropdown and a text box appears. Say you are an existing customer and the \u201cHow did you hear about us?\u201d question disappears. The visitor sees a shorter, more relevant form, and you receive cleaner data.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It is also one of the features WordPress form plugins like to charge for. This guide explains how conditional logic works, shows practical examples, and covers a subtle problem most tutorials skip: what happens on the server.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How conditional logic works<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Every rule has the same three parts: a condition, an operator and an action. The condition looks at a field, such as \u201cProject type\u201d. The operator compares it, for example \u201cis equal to\u201d or \u201cis not empty\u201d. The action decides what happens, such as showing, hiding or requiring another field.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Put together, a rule reads like a sentence: if Project type is \u201cWebsite redesign\u201d, then show \u201cCurrent website address\u201d and make it required. You can usually combine several conditions and decide whether any or all of them must match.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Five practical examples<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">These patterns cover most real-world forms:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Show an \u201cOther, please specify\u201d field only when \u201cOther\u201d is selected<\/li><li>Ask for a company name only when the visitor says they are enquiring for a business<\/li><li>Reveal a file upload only for people applying for a role that needs a portfolio<\/li><li>Require a phone number only when the visitor picks \u201cCall me\u201d as their preferred contact method<\/li><li>Show different final questions for new customers and existing ones<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Keep it simple<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">It is tempting to make every field conditional. Resist that. Forms with long chains of rules are hard to test, and a mistake can hide a required field from everyone. Start with the obvious cases, test each path, and stop when the form feels short.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Always test both directions. Fill in the form so a field appears, then change your answer and check that it disappears and no stale value is submitted.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The problem with browser-only logic<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Most form logic runs in the visitor\u2019s browser using JavaScript. That is fine for convenience, but it is not security. Anyone can turn off JavaScript, edit the page or send data directly to your site. If your server trusts whatever arrives, a required field can be skipped and a field that should have been hidden can be submitted with unexpected content.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Good practice is to evaluate the rules again on the server. VuloForm does exactly that: the rules are checked again on your site, a field hidden by its rules is never stored, and a required field cannot be skipped by turning off JavaScript. The same applies to calculations, which are re-computed on the server.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What other plugins charge for it<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In our check on 10 October 2026, Contact Form 7 needed a third-party add-on for conditional logic. WPForms, Gravity Forms and Formidable included it on paid plans, and Ninja Forms offered it as an add-on from its Plus plan. Fluent Forms, Forminator and VuloForm include it in the free plugin.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you are building a form that depends on logic, check the plan you would actually need, not just the headline price.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Setting up a rule in VuloForm<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In the builder, select the field you want to control. In the inspector on the right, open its conditional logic settings, choose the field to watch, the operator and the value, and pick whether to show or hide. Use the preview to try each path; nothing you enter there is sent or saved.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">When you publish, the same rules are enforced on submission, so what you tested in the preview matches what is stored.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Common mistakes to avoid<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A short checklist before you publish:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Do not make a field required and hidden at the same time without a rule that reveals it<\/li><li>Avoid circular rules, where two fields depend on each other<\/li><li>Use clear option labels, since rules often match on them<\/li><li>Test with keyboard only and on a phone<\/li><li>Re-test after you rename a field or option<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Questions people ask<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Can conditional logic slow a form down? Not noticeably. The rules are small, and the browser evaluates them instantly as someone fills in the form. The page weight matters more, and VuloForm\u2019s public form ships no React and no jQuery.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">What if a visitor has JavaScript turned off? On your own WordPress site the form still works without JavaScript, and because the rules are checked again on the server, nothing can slip through that should not.<\/p>\n\n\n\n<div class=\"wp-block-group vf-outro is-layout-flow wp-block-group-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Conditional logic makes forms shorter, friendlier and more accurate, and it should not cost a licence. VuloForm includes it in the free plugin, with rules enforced on your server as well as in the browser.<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Learn how conditional logic works in WordPress forms, with real examples, common mistakes, and why server-side checking matters.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[6],"tags":[],"class_list":["post-90","post","type-post","status-publish","format-standard","hentry","category-how-to"],"_links":{"self":[{"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/posts\/90","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/comments?post=90"}],"version-history":[{"count":0,"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/posts\/90\/revisions"}],"wp:attachment":[{"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/media?parent=90"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/categories?post=90"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cus.dualcube.com\/mvx1\/wp-json\/wp\/v2\/tags?post=90"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}