{"id":3324,"date":"2026-02-22T05:00:00","date_gmt":"2026-02-22T05:00:00","guid":{"rendered":"https:\/\/pirhome.com\/?p=3322"},"modified":"2026-02-22T05:00:00","modified_gmt":"2026-02-22T05:00:00","slug":"pir-smart-bathrooms","status":"publish","type":"post","link":"http:\/\/www.pirhome.com\/?p=3324","title":{"rendered":"PIR Sensor for Smart Bathrooms: Occupancy and Automation"},"content":{"rendered":"<h2>Introduction<\/h2>\n<p>Smart bathrooms use sensors to automate lighting, ventilation, and even hygiene features. PIR sensors play a key role in detecting occupancy and triggering these functions.<\/p>\n<h2>Applications in Bathrooms<\/h2>\n<h3>Occupancy Detection<\/h3>\n<p>Detect when someone enters the bathroom. Used for:<\/p>\n<ul>\n<li>Turning on lights automatically.<\/li>\n<li>Activating ventilation fans.<\/li>\n<li>Displaying &#8220;occupied&#8221; sign outside.<\/li>\n<\/ul>\n<h3>Lighting Control<\/h3>\n<p>Lights turn on when motion detected, turn off after period of inactivity (with sufficient delay to avoid turning off while using toilet).<\/p>\n<h3>Ventilation Control<\/h3>\n<p>Fan turns on when occupancy detected and runs for set time after exit to remove odors and moisture.<\/p>\n<h3>Hygiene Monitoring<\/h3>\n<p>Detect if soap dispenser or towel dispenser is accessed; trigger alerts when supplies low.<\/p>\n<h2>Sensor Placement<\/h2>\n<ul>\n<li><strong>Ceiling-mounted:<\/strong> Best coverage for entire room.<\/li>\n<li><strong>Wall-mounted near door:<\/strong> Detect entry\/exit.<\/li>\n<li><strong>Inside shower stall:<\/strong> Waterproof sensor required.<\/li>\n<\/ul>\n<h2>Special Considerations for Bathrooms<\/h2>\n<h3>Humidity and Steam<\/h3>\n<p>Bathrooms have high humidity and steam, which can:<\/p>\n<ul>\n<li>Condense on lens, blocking IR.<\/li>\n<li>Corrode electronics.<\/li>\n<\/ul>\n<p>Use sensors with conformal coating or IP-rated enclosures. Consider heated lenses to prevent condensation.<\/p>\n<h3>False Triggers from Water Flow<\/h3>\n<p>Running water (shower, sink) can cause temperature changes that may trigger sensor. Proper placement away from direct water spray helps.<\/p>\n<h3>Privacy<\/h3>\n<p>PIR sensors are privacy-preserving \u2013 they don&#8217;t capture images, making them ideal for bathrooms.<\/p>\n<h2>Integration with Building Automation<\/h2>\n<p>PIR sensors can connect to building management systems via:<\/p>\n<ul>\n<li>Wired digital inputs.<\/li>\n<li>Wireless protocols (Zigbee, Z-Wave, Bluetooth).<\/li>\n<li>KNX or BACnet systems.<\/li>\n<\/ul>\n<h2>Case Study: Hotel Smart Bathroom<\/h2>\n<p>A hotel chain installed PIR sensors in bathroom ceilings. When a guest entered, lights turned on and fan started. After 5 minutes of no motion, lights dimmed to night-light level. Energy savings: 40% compared to always-on lighting.<\/p>\n<h2>Code Example: Bathroom Automation with Arduino<\/h2>\n<pre><code>int pirPin = 2;\nint lightRelay = 3;\nint fanRelay = 4;\nunsigned long lastMotion = 0;\nconst unsigned long lightTimeout = 300000; \/\/ 5 minutes\nconst unsigned long fanTimeout = 600000;   \/\/ 10 minutes\nbool occupied = false;\n\nvoid loop() {\n    if (digitalRead(pirPin) == HIGH) {\n        lastMotion = millis();\n        if (!occupied) {\n            occupied = true;\n            digitalWrite(lightRelay, HIGH);\n            digitalWrite(fanRelay, HIGH);\n        }\n    }\n    \n    if (occupied && (millis() - lastMotion > lightTimeout)) {\n        digitalWrite(lightRelay, LOW); \/\/ Lights off after timeout\n    }\n    \n    if (occupied && (millis() - lastMotion > fanTimeout)) {\n        digitalWrite(fanRelay, LOW);   \/\/ Fan off after longer timeout\n        occupied = false;               \/\/ Reset occupancy\n    }\n}\n<\/code><\/pre>\n<h2>Conclusion<\/h2>\n<p>PIR sensors make bathrooms smarter, more energy-efficient, and more hygienic. With proper environmental protection, they work reliably in this challenging environment.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction Smart bathrooms use sensors to automate lighting, ventilation, and even hygiene features. PIR sensors play a key role in detecting occupancy and triggering these functions. Applications in Bathrooms Occupancy Detection Detect when someone enters the bathroom. Used for: Turning on lights automatically. Activating ventilation fans. Displaying &#8220;occupied&#8221; sign outside. Lighting Control Lights turn on [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[],"class_list":["post-3324","post","type-post","status-publish","format-standard","hentry","category-reference"],"blocksy_meta":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\r\n<title>PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME<\/title>\r\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\r\n<link rel=\"canonical\" href=\"http:\/\/www.pirhome.com\/?p=3324\" \/>\r\n<meta property=\"og:locale\" content=\"en_US\" \/>\r\n<meta property=\"og:type\" content=\"article\" \/>\r\n<meta property=\"og:title\" content=\"PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME\" \/>\r\n<meta property=\"og:description\" content=\"Introduction Smart bathrooms use sensors to automate lighting, ventilation, and even hygiene features. PIR sensors play a key role in detecting occupancy and triggering these functions. Applications in Bathrooms Occupancy Detection Detect when someone enters the bathroom. Used for: Turning on lights automatically. Activating ventilation fans. Displaying &#8220;occupied&#8221; sign outside. Lighting Control Lights turn on [&hellip;]\" \/>\r\n<meta property=\"og:url\" content=\"http:\/\/www.pirhome.com\/?p=3324\" \/>\r\n<meta property=\"og:site_name\" content=\"PIRHOME\" \/>\r\n<meta property=\"article:published_time\" content=\"2026-02-22T05:00:00+00:00\" \/>\r\n<meta name=\"author\" content=\"nic@nicsky.com\" \/>\r\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\r\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"nic@nicsky.com\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\r\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324#article\",\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324\"},\"author\":{\"name\":\"nic@nicsky.com\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#\\\/schema\\\/person\\\/41049b5236f9c77c9314997d070db3e3\"},\"headline\":\"PIR Sensor for Smart Bathrooms: Occupancy and Automation\",\"datePublished\":\"2026-02-22T05:00:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324\"},\"wordCount\":306,\"commentCount\":0,\"publisher\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#organization\"},\"articleSection\":[\"Reference\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"http:\\\/\\\/www.pirhome.com\\\/?p=3324#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324\",\"url\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324\",\"name\":\"PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME\",\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#website\"},\"datePublished\":\"2026-02-22T05:00:00+00:00\",\"breadcrumb\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"http:\\\/\\\/www.pirhome.com\\\/?p=3324\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/?p=3324#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"http:\\\/\\\/www.pirhome.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"PIR Sensor for Smart Bathrooms: Occupancy and Automation\"}]},{\"@type\":\"WebSite\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#website\",\"url\":\"http:\\\/\\\/www.pirhome.com\\\/\",\"name\":\"PIRHOME\",\"description\":\"PIR &amp; Motion Sensor\",\"publisher\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"http:\\\/\\\/www.pirhome.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#organization\",\"name\":\"PIRHOME\",\"url\":\"http:\\\/\\\/www.pirhome.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"http:\\\/\\\/www.pirhome.com\\\/wp-content\\\/uploads\\\/2026\\\/02\\\/cropped-\u5fae\u4fe1\u56fe\u7247_2026-02-19_222409_472.jpg\",\"contentUrl\":\"http:\\\/\\\/www.pirhome.com\\\/wp-content\\\/uploads\\\/2026\\\/02\\\/cropped-\u5fae\u4fe1\u56fe\u7247_2026-02-19_222409_472.jpg\",\"width\":512,\"height\":512,\"caption\":\"PIRHOME\"},\"image\":{\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"http:\\\/\\\/www.pirhome.com\\\/#\\\/schema\\\/person\\\/41049b5236f9c77c9314997d070db3e3\",\"name\":\"nic@nicsky.com\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g\",\"caption\":\"nic@nicsky.com\"},\"sameAs\":[\"http:\\\/\\\/www.pirhome.com\"],\"url\":\"http:\\\/\\\/www.pirhome.com\\\/?author=1\"}]}<\/script>\r\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME","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":"http:\/\/www.pirhome.com\/?p=3324","og_locale":"en_US","og_type":"article","og_title":"PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME","og_description":"Introduction Smart bathrooms use sensors to automate lighting, ventilation, and even hygiene features. PIR sensors play a key role in detecting occupancy and triggering these functions. Applications in Bathrooms Occupancy Detection Detect when someone enters the bathroom. Used for: Turning on lights automatically. Activating ventilation fans. Displaying &#8220;occupied&#8221; sign outside. Lighting Control Lights turn on [&hellip;]","og_url":"http:\/\/www.pirhome.com\/?p=3324","og_site_name":"PIRHOME","article_published_time":"2026-02-22T05:00:00+00:00","author":"nic@nicsky.com","twitter_card":"summary_large_image","twitter_misc":{"Written by":"nic@nicsky.com","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"http:\/\/www.pirhome.com\/?p=3324#article","isPartOf":{"@id":"http:\/\/www.pirhome.com\/?p=3324"},"author":{"name":"nic@nicsky.com","@id":"http:\/\/www.pirhome.com\/#\/schema\/person\/41049b5236f9c77c9314997d070db3e3"},"headline":"PIR Sensor for Smart Bathrooms: Occupancy and Automation","datePublished":"2026-02-22T05:00:00+00:00","mainEntityOfPage":{"@id":"http:\/\/www.pirhome.com\/?p=3324"},"wordCount":306,"commentCount":0,"publisher":{"@id":"http:\/\/www.pirhome.com\/#organization"},"articleSection":["Reference"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["http:\/\/www.pirhome.com\/?p=3324#respond"]}]},{"@type":"WebPage","@id":"http:\/\/www.pirhome.com\/?p=3324","url":"http:\/\/www.pirhome.com\/?p=3324","name":"PIR Sensor for Smart Bathrooms: Occupancy and Automation - PIRHOME","isPartOf":{"@id":"http:\/\/www.pirhome.com\/#website"},"datePublished":"2026-02-22T05:00:00+00:00","breadcrumb":{"@id":"http:\/\/www.pirhome.com\/?p=3324#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["http:\/\/www.pirhome.com\/?p=3324"]}]},{"@type":"BreadcrumbList","@id":"http:\/\/www.pirhome.com\/?p=3324#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"http:\/\/www.pirhome.com\/"},{"@type":"ListItem","position":2,"name":"PIR Sensor for Smart Bathrooms: Occupancy and Automation"}]},{"@type":"WebSite","@id":"http:\/\/www.pirhome.com\/#website","url":"http:\/\/www.pirhome.com\/","name":"PIRHOME","description":"PIR &amp; Motion Sensor","publisher":{"@id":"http:\/\/www.pirhome.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"http:\/\/www.pirhome.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"http:\/\/www.pirhome.com\/#organization","name":"PIRHOME","url":"http:\/\/www.pirhome.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"http:\/\/www.pirhome.com\/#\/schema\/logo\/image\/","url":"http:\/\/www.pirhome.com\/wp-content\/uploads\/2026\/02\/cropped-\u5fae\u4fe1\u56fe\u7247_2026-02-19_222409_472.jpg","contentUrl":"http:\/\/www.pirhome.com\/wp-content\/uploads\/2026\/02\/cropped-\u5fae\u4fe1\u56fe\u7247_2026-02-19_222409_472.jpg","width":512,"height":512,"caption":"PIRHOME"},"image":{"@id":"http:\/\/www.pirhome.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"http:\/\/www.pirhome.com\/#\/schema\/person\/41049b5236f9c77c9314997d070db3e3","name":"nic@nicsky.com","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/271d4eaab48e299e4fce771a8c43c537be3ac77a3115cc7de802a6c8b692d971?s=96&d=mm&r=g","caption":"nic@nicsky.com"},"sameAs":["http:\/\/www.pirhome.com"],"url":"http:\/\/www.pirhome.com\/?author=1"}]}},"_links":{"self":[{"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/posts\/3324","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3324"}],"version-history":[{"count":1,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/posts\/3324\/revisions"}],"predecessor-version":[{"id":3354,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=\/wp\/v2\/posts\/3324\/revisions\/3354"}],"wp:attachment":[{"href":"http:\/\/www.pirhome.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3324"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3324"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.pirhome.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3324"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}