Testing Tools

Smoke vs Sanity Testing: Differences with Real Examples

A clear comparison of smoke and sanity testing with release-day examples, a side-by-side table, sample checklists and how teams automate each one.

✍️ By QA Jobs India📅 15 Nov 2026⏱ 7 min read

A build lands on the QA server at 6 pm. The release is tomorrow morning. Someone asks, “Can you do a quick check before we start?” Whether that quick check is a smoke test or a sanity test depends on what changed in the build, and confusing the two can mean either wasting an evening or missing a broken feature. Smoke vs sanity testing is also one of the most common fresher interview questions, so it pays to understand the difference properly.

This guide explains both with real scenarios from typical Indian projects, such as an e-commerce app and a banking portal, shows a side-by-side comparison, gives sample checklists, and covers how teams automate each.

Key takeaways

  • Smoke testing is a shallow, wide check that a new build is stable enough for further testing.
  • Sanity testing is a narrow, focused check that a specific change or fix works and has not broken its immediate surroundings.
  • Smoke usually runs on every new build; sanity usually runs after small changes, hot fixes or late bug fixes.
  • Both are subsets of broader testing; neither replaces regression testing.
  • In interviews, explain each with an example from a project, not just definitions.

What is smoke testing?

Smoke testing checks whether the most important functions of a new build work at all. The name is often traced to hardware testing: power on the device and see whether smoke comes out. If the basics fail, there is no point testing further.

A smoke test answers one question: is this build testable?

Real example: e-commerce app

A new build of an online store arrives on staging. The smoke suite checks:

  • The home page loads without errors.
  • A user can log in.
  • Search returns results.
  • A product can be added to the cart.
  • The checkout page opens.
  • The admin panel loads.

If login fails, the build is rejected and sent back to developers. Nobody spends hours testing coupon rules on a build where users cannot sign in.

Key characteristics

  • Wide coverage, shallow depth.
  • Run on every new build, often automatically in CI.
  • Takes minutes, not hours.
  • Usually scripted and stable over time.
  • Can be done by QA or developers.

What is sanity testing?

Sanity testing checks that a specific change or fix behaves correctly, and that closely related functionality still works. It is a narrow, deeper check done when there is no time for full regression.

A sanity test answers a different question: does this specific change make sense and work?

Real example: banking portal

In the final days before a release, developers fix a bug where the fund transfer screen showed the wrong daily limit for savings accounts. A sanity check covers:

  • The daily limit now shows correctly for savings accounts.
  • Current accounts still show their own correct limit.
  • A transfer within the limit succeeds.
  • A transfer above the limit shows the right error.
  • The transfer history page still lists the new transaction.

You do not re-test loans, cards or the profile page. The scope is the fix and its neighbours.

Key characteristics

  • Narrow coverage, deeper on the changed area.
  • Run after bug fixes, small enhancements or hot fixes.
  • Often unscripted or lightly documented, guided by the tester’s understanding of the change.
  • Done by testers who know the feature.

Smoke vs sanity testing: side-by-side comparison

AspectSmoke testingSanity testing
PurposeIs the build stable enough to test?Does this change or fix work?
ScopeWide and shallowNarrow and focused
WhenEvery new buildAfter small changes or fixes
DocumentationUsually scriptedOften unscripted
WhoQA or developers, often automatedQA testers familiar with the feature
Outcome if failedBuild rejectedChange or fix rejected
Relation to regressionEntry gate before regressionQuick subset when full regression is not possible

Some textbooks describe sanity testing as a subset of regression testing and smoke testing as a subset of acceptance or build verification testing. Terms vary between companies, so in interviews, explain what your team meant by each.

When to use each: a decision checklist

Use this quick checklist when a build arrives:

  • Is this a brand-new build with many changes? Run smoke first.
  • Did smoke pass? Move to functional and regression testing.
  • Is this a small fix or change late in the cycle? Run sanity on that area.
  • Is it a production hot fix? Run sanity on the fix, then a short smoke on production-like data if possible.
  • Is there enough time for full regression? If yes, do it; sanity is not a substitute.

Sample smoke and sanity checklists

Smoke checklist for a job portal

  1. Home page loads with job listings.
  2. Candidate can register and log in.
  3. Job search by keyword and location returns results.
  4. Job detail page opens.
  5. Candidate can upload a resume.
  6. Employer can log in and view the dashboard.

Sanity checklist after a fix to resume upload size limits

  1. A 1 MB PDF uploads successfully.
  2. A file just under the new limit uploads successfully.
  3. A file just over the limit shows the correct error message.
  4. Unsupported formats are still rejected.
  5. The uploaded resume appears on the candidate profile.
  6. Applying to a job attaches the latest resume.

Notice how the sanity checklist uses boundary values around the changed limit. Good test design matters even in quick checks; our guide on how to write test cases explains the techniques.

Automating smoke and sanity tests

Smoke tests are ideal for automation because they are stable and run often. A common approach is to tag a small set of critical tests and run only those on every build.

With TestNG, use groups:

import org.testng.annotations.Test;

public class CheckoutTests {

    @Test(groups = {"smoke"})
    public void userCanOpenCheckout() {
        // critical path steps
    }

    @Test(groups = {"regression"})
    public void couponAppliesToEligibleItemsOnly() {
        // detailed rule checks
    }
}

Then include only the smoke group in your suite file. Our TestNG tutorial shows the testng.xml setup.

With Playwright Test, add a tag to the test title and filter with --grep:

import { test, expect } from '@playwright/test';

test('home page shows job listings @smoke', async ({ page }) => {
  await page.goto('https://example.com');
  await expect(page).toHaveTitle(/Example/);
});
npx playwright test --grep @smoke

Sanity tests are harder to automate up front because they depend on what changed. Teams often run a relevant subset of the regression suite by tag or by folder, plus some manual checks. See the Playwright documentation for more on filtering tests.

Common mistakes teams make

  • Calling everything a smoke test. A 400-case “smoke suite” that takes a day is regression, not smoke.
  • Skipping smoke when in a hurry. Testing on a broken build wastes far more time than the ten-minute smoke run.
  • Treating sanity as a replacement for regression. It reduces risk when time is short, but it does not remove it. Flag the remaining risk to the team.
  • Not documenting sanity scope. Even a short note like “checked fix X plus areas A and B” protects you if something else breaks later.

How to answer smoke vs sanity testing in an interview

A strong answer has three parts:

  1. One-line definitions. “Smoke checks if the build is stable enough to test. Sanity checks if a specific change works.”
  2. A real example of each. Use the e-commerce and banking examples above, or better, your own.
  3. The practical difference. “Smoke is wide and shallow on every build; sanity is narrow and deeper after a change.”

This question often appears together with retesting vs regression and severity vs priority. You will find more of these in our list of manual testing interview questions, and the wider context in our guide to the types of software testing.

🚀 Preparing for manual testing interviews?

QA Jobs India shares 100+ fresh QA & software testing openings every morning — manual, automation, API and remote roles.

See today’s QA jobs →

FAQs

What is the main difference between smoke and sanity testing?

Smoke testing checks the overall stability of a new build across critical features. Sanity testing checks that a specific change or bug fix works correctly along with closely related areas. Smoke is wide and shallow; sanity is narrow and focused.

Which comes first, smoke or sanity testing?

Smoke testing usually comes first on a new build. Sanity testing happens later, typically after a bug fix or small change on an already stable build.

Is smoke testing manual or automated?

It can be either, but it is a strong candidate for automation because it runs on every build and covers stable, critical paths. Many teams run an automated smoke suite in CI.

Is sanity testing the same as regression testing?

No. Sanity testing is a quick, focused check on a change and its immediate surroundings. Regression testing is broader and checks that existing functionality across the application still works after changes.

Can smoke testing be done in production?

Yes. Many teams run a short, safe smoke check right after deployment to confirm key pages and flows work, using test accounts and avoiding actions that affect real customers.

Conclusion

Write a six-step smoke checklist for the application you test today, and time how long it takes to run. If it takes more than about 30 minutes, trim it down to the true critical paths, then tag those tests in your automation so they run on every build.

SIGN UP ONCE
Once you sign up, you get all this
Sign up now
  • 100+ fresh QA jobs daily + Direct HR email IDsLive every morning at 9 AM — apply straight to HR
  • Weekly Mega Job Fair800+ QA jobs from India & around the world, every week
  • Certified QA coursesUp to 3 courses included · all 17 for ₹500
  • AI ATS Resume BuilderFree resume points included
  • Full LinkedQA feedEvery post, fully unblurred
  • Complete QA Material libraryInterview Q&A, cheat sheets, templates & roadmaps

Instant activation right after payment · One login for jobs, courses, resume & LinkedQA

💎 Get every QA opening, every day

Join QA Jobs India Premium for 100+ verified QA jobs daily with HR contact details.

✓ You're subscribed — job alerts arrive daily at 9 AM
Scroll to Top