{"id":52,"date":"2026-02-28T06:23:17","date_gmt":"2026-02-28T06:23:17","guid":{"rendered":"https:\/\/gigz.pk\/googlesheets\/?post_type=lesson&#038;p=52"},"modified":"2026-03-27T12:28:43","modified_gmt":"2026-03-27T12:28:43","slug":"if-function","status":"publish","type":"lesson","link":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/","title":{"rendered":"\u00a0IF Function"},"content":{"rendered":"\n<p>The <strong>IF<\/strong> function in <strong>Google Sheets<\/strong> is a logical function that allows you to make decisions based on a condition. It checks whether a condition is true or false and returns different values accordingly.<\/p>\n\n\n\n<p>This function is widely used for data analysis, reporting, and decision-making.<\/p>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>1. What is the IF Function?<\/strong><\/h1>\n\n\n\n<p>The IF function evaluates a condition and returns one value if the condition is true and another if it is false.<\/p>\n\n\n\n<p><strong>Syntax:<\/strong><br><code>=IF(logical_test, value_if_true, value_if_false)<\/code><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>logical_test<\/strong> \u2014 The condition to check (e.g., A1&gt;50)<\/li>\n\n\n\n<li><strong>value_if_true<\/strong> \u2014 The value returned if the condition is true<\/li>\n\n\n\n<li><strong>value_if_false<\/strong> \u2014 The value returned if the condition is false<\/li>\n<\/ul>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>2. Simple Example<\/strong><\/h1>\n\n\n\n<p><code>=IF(B2&gt;=50, \"Pass\", \"Fail\")<\/code><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>If the value in B2 is 50 or more, the result will be \u201cPass\u201d<\/li>\n\n\n\n<li>If the value is less than 50, the result will be \u201cFail\u201d<\/li>\n<\/ul>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>3. Nested IF Function<\/strong><\/h1>\n\n\n\n<p>You can use multiple IF statements to test more than one condition.<\/p>\n\n\n\n<p><strong>Example:<\/strong><br><code>=IF(C2&gt;=90, \"Excellent\", IF(C2&gt;=75, \"Good\", IF(C2&gt;=50, \"Average\", \"Poor\")))<\/code><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Checks multiple score ranges and returns a corresponding result<\/li>\n\n\n\n<li>Useful for grading or categorizing data<\/li>\n<\/ul>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>4. Common Use Cases<\/strong><\/h1>\n\n\n\n<p>Assign grades based on scores<br>Categorize sales as \u201cHigh,\u201d \u201cMedium,\u201d or \u201cLow\u201d<br>Highlight overdue tasks or status<br>Create dynamic labels in dashboards<\/p>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>5. Tips for Using IF<\/strong><\/h1>\n\n\n\n<p>Keep logical tests simple to avoid confusion<br>Use cell references instead of typing numbers directly<br>Combine IF with other functions like AND, OR, or ISBLANK for advanced logic<\/p>\n\n\n\n<h1 class=\"wp-block-heading\"><strong>Conclusion<\/strong><\/h1>\n\n\n\n<p>The IF function in Google Sheets is a versatile tool for decision-making and data categorization.<\/p>\n\n\n\n<p>By mastering IF and nested IF statements, you can create dynamic spreadsheets that respond automatically to changing data, making analysis and reporting faster and more accurate.<\/p>\n\n\n<div class=\"yoast-breadcrumbs\"><span><span><a href=\"https:\/\/gigz.pk\/googlesheets\/\">Home<\/a><\/span> \u00bb <span class=\"breadcrumb_last\" aria-current=\"page\">GOOGLE SHEETS FUNDAMENTALS (GSF) > Essential Formulas > IF Function<\/span><\/span><\/div>\n\n\n<div class=\"schema-faq wp-block-yoast-faq-block\"><div class=\"schema-faq-section\" id=\"faq-question-1774614470459\"><strong class=\"schema-faq-question\"><\/strong> <p class=\"schema-faq-answer\"><\/p> <\/div> <\/div>\n","protected":false},"menu_order":15,"template":"","class_list":["post-52","lesson","type-lesson","status-publish","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>\u00a0IF Function - Collaborate. Analyze. Automate.<\/title>\n<meta name=\"description\" content=\"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u00a0IF Function - Collaborate. Analyze. Automate.\" \/>\n<meta property=\"og:description\" content=\"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/\" \/>\n<meta property=\"og:site_name\" content=\"Collaborate. Analyze. Automate.\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-27T12:28:43+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":[\"WebPage\",\"FAQPage\"],\"@id\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/lesson\\\/if-function\\\/\",\"url\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/lesson\\\/if-function\\\/\",\"name\":\"\u00a0IF Function - Collaborate. Analyze. Automate.\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/#website\"},\"datePublished\":\"2026-02-28T06:23:17+00:00\",\"dateModified\":\"2026-03-27T12:28:43+00:00\",\"description\":\"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/lesson\\\/if-function\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/lesson\\\/if-function\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/lesson\\\/if-function\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"GOOGLE SHEETS FUNDAMENTALS (GSF) > Essential Formulas > IF Function\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/#website\",\"url\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/\",\"name\":\"Collaborate. Analyze. Automate.\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/gigz.pk\\\/googlesheets\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u00a0IF Function - Collaborate. Analyze. Automate.","description":"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/","og_locale":"en_US","og_type":"article","og_title":"\u00a0IF Function - Collaborate. Analyze. Automate.","og_description":"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.","og_url":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/","og_site_name":"Collaborate. Analyze. Automate.","article_modified_time":"2026-03-27T12:28:43+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":["WebPage","FAQPage"],"@id":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/","url":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/","name":"\u00a0IF Function - Collaborate. Analyze. Automate.","isPartOf":{"@id":"https:\/\/gigz.pk\/googlesheets\/#website"},"datePublished":"2026-02-28T06:23:17+00:00","dateModified":"2026-03-27T12:28:43+00:00","description":"Learn Google Sheets IF function to create logical tests, use nested IFs, and automate decision-making in your spreadsheets.","breadcrumb":{"@id":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/gigz.pk\/googlesheets\/lesson\/if-function\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/gigz.pk\/googlesheets\/"},{"@type":"ListItem","position":2,"name":"GOOGLE SHEETS FUNDAMENTALS (GSF) > Essential Formulas > IF Function"}]},{"@type":"WebSite","@id":"https:\/\/gigz.pk\/googlesheets\/#website","url":"https:\/\/gigz.pk\/googlesheets\/","name":"Collaborate. Analyze. Automate.","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/gigz.pk\/googlesheets\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/gigz.pk\/googlesheets\/wp-json\/wp\/v2\/lesson\/52","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gigz.pk\/googlesheets\/wp-json\/wp\/v2\/lesson"}],"about":[{"href":"https:\/\/gigz.pk\/googlesheets\/wp-json\/wp\/v2\/types\/lesson"}],"wp:attachment":[{"href":"https:\/\/gigz.pk\/googlesheets\/wp-json\/wp\/v2\/media?parent=52"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}