{"id":1058,"date":"2026-05-22T12:37:22","date_gmt":"2026-05-22T07:07:22","guid":{"rendered":"https:\/\/capkit.in\/?post_type=product&#038;p=1058"},"modified":"2026-06-28T00:12:36","modified_gmt":"2026-06-27T18:42:36","slug":"digital-liquid-flow-sensor-for-microcontroller-projects","status":"publish","type":"product","link":"https:\/\/capkit.in\/?product=digital-liquid-flow-sensor-for-microcontroller-projects","title":{"rendered":"YF-S401 Hall Effect Water Flow Sensor for Arduino, ESP32 &#038; Raspberry Pi"},"content":{"rendered":"<p class=\"PDq2pG_selectionAnchorContainer\" data-start=\"552\" data-end=\"948\">The <strong data-start=\"556\" data-end=\"585\">YF-S401 Water Flow Sensor<\/strong> is a high-quality liquid flow measurement sensor featuring a precision turbine rotor and Hall-effect sensing technology. As water passes through the sensor, the internal rotor spins and produces digital pulse outputs proportional to the flow rate. These pulses can be counted by a microcontroller to calculate both instantaneous flow and total water consumption.<\/p>\n<p data-start=\"950\" data-end=\"1369\">Its compact size and low flow measurement range make it ideal for applications such as water dispensers, coffee machines, irrigation systems, laboratory equipment, cooling systems, and smart water monitoring. Compatible with Arduino, ESP32, Raspberry Pi, STM32, PIC, and other development boards, the YF-S401 offers stable performance, low power consumption, and easy installation.<\/p>\n<hr data-start=\"1371\" data-end=\"1374\" \/>\n<h1 data-section-id=\"1fah8gx\" data-start=\"1376\" data-end=\"1386\">Features<\/h1>\n<ul data-start=\"1388\" data-end=\"1745\">\n<li data-section-id=\"dz18wh\" data-start=\"1388\" data-end=\"1426\">High-quality Hall-effect flow sensor<\/li>\n<li data-section-id=\"1a7c1qa\" data-start=\"1427\" data-end=\"1465\">Measures clean water flow accurately<\/li>\n<li data-section-id=\"4tu7de\" data-start=\"1466\" data-end=\"1488\">Digital pulse output<\/li>\n<li data-section-id=\"1pi3mw8\" data-start=\"1489\" data-end=\"1521\">Compact and lightweight design<\/li>\n<li data-section-id=\"jhmxae\" data-start=\"1522\" data-end=\"1545\">Low power consumption<\/li>\n<li data-section-id=\"1emvyce\" data-start=\"1546\" data-end=\"1566\">Fast response time<\/li>\n<li data-section-id=\"38chen\" data-start=\"1567\" data-end=\"1591\">Waterproof sensor body<\/li>\n<li data-section-id=\"k8l5sc\" data-start=\"1592\" data-end=\"1622\">Durable plastic construction<\/li>\n<li data-section-id=\"dyu5bj\" data-start=\"1623\" data-end=\"1664\">Easy to interface with microcontrollers<\/li>\n<li data-section-id=\"112163y\" data-start=\"1665\" data-end=\"1698\">Stable and reliable performance<\/li>\n<li data-section-id=\"1wdzf4p\" data-start=\"1699\" data-end=\"1718\">Long service life<\/li>\n<li data-section-id=\"1h7ypz\" data-start=\"1719\" data-end=\"1745\">Simple 3-wire connection<\/li>\n<\/ul>\n<hr data-start=\"1747\" data-end=\"1750\" \/>\n<h1 data-section-id=\"1spgaq0\" data-start=\"1752\" data-end=\"1768\">Specifications<\/h1>\n<div class=\"TyagGW_tableContainer\">\n<div class=\"group TyagGW_tableWrapper flex flex-col-reverse w-fit\" tabindex=\"-1\">\n<table class=\"w-fit min-w-(--thread-content-width)\" data-start=\"1770\" data-end=\"2291\">\n<thead data-start=\"1770\" data-end=\"1795\">\n<tr data-start=\"1770\" data-end=\"1795\">\n<th class=\"last:pe-10\" data-start=\"1770\" data-end=\"1786\" data-col-size=\"sm\">Specification<\/th>\n<th class=\"last:pe-10\" data-start=\"1786\" data-end=\"1795\" data-col-size=\"sm\">Value<\/th>\n<\/tr>\n<\/thead>\n<tbody data-start=\"1821\" data-end=\"2291\">\n<tr data-start=\"1821\" data-end=\"1840\">\n<td data-start=\"1821\" data-end=\"1829\" data-col-size=\"sm\">Model<\/td>\n<td data-start=\"1829\" data-end=\"1840\" data-col-size=\"sm\">YF-S401<\/td>\n<\/tr>\n<tr data-start=\"1841\" data-end=\"1888\">\n<td data-start=\"1841\" data-end=\"1855\" data-col-size=\"sm\">Sensor Type<\/td>\n<td data-start=\"1855\" data-end=\"1888\" data-col-size=\"sm\">Hall Effect Water Flow Sensor<\/td>\n<\/tr>\n<tr data-start=\"1889\" data-end=\"1924\">\n<td data-start=\"1889\" data-end=\"1909\" data-col-size=\"sm\">Operating Voltage<\/td>\n<td data-start=\"1909\" data-end=\"1924\" data-col-size=\"sm\">DC 3.5V\u201324V<\/td>\n<\/tr>\n<tr data-start=\"1925\" data-end=\"1956\">\n<td data-start=\"1925\" data-end=\"1947\" data-col-size=\"sm\">Recommended Voltage<\/td>\n<td data-start=\"1947\" data-end=\"1956\" data-col-size=\"sm\">DC 5V<\/td>\n<\/tr>\n<tr data-start=\"1957\" data-end=\"1986\">\n<td data-start=\"1957\" data-end=\"1977\" data-col-size=\"sm\">Operating Current<\/td>\n<td data-start=\"1977\" data-end=\"1986\" data-col-size=\"sm\">\u226415mA<\/td>\n<\/tr>\n<tr data-start=\"1987\" data-end=\"2015\">\n<td data-start=\"1987\" data-end=\"2000\" data-col-size=\"sm\">Flow Range<\/td>\n<td data-start=\"2000\" data-end=\"2015\" data-col-size=\"sm\">0.3\u20136 L\/min<\/td>\n<\/tr>\n<tr data-start=\"2016\" data-end=\"2049\">\n<td data-start=\"2016\" data-end=\"2032\" data-col-size=\"sm\">Output Signal<\/td>\n<td data-col-size=\"sm\" data-start=\"2032\" data-end=\"2049\">Digital Pulse<\/td>\n<\/tr>\n<tr data-start=\"2050\" data-end=\"2078\">\n<td data-start=\"2050\" data-end=\"2061\" data-col-size=\"sm\">Accuracy<\/td>\n<td data-start=\"2061\" data-end=\"2078\" data-col-size=\"sm\">\u00b15% (Typical)<\/td>\n<\/tr>\n<tr data-start=\"2079\" data-end=\"2121\">\n<td data-start=\"2079\" data-end=\"2103\" data-col-size=\"sm\">Operating Temperature<\/td>\n<td data-start=\"2103\" data-end=\"2121\" data-col-size=\"sm\">-20\u00b0C to +80\u00b0C<\/td>\n<\/tr>\n<tr data-start=\"2122\" data-end=\"2157\">\n<td data-start=\"2122\" data-end=\"2143\" data-col-size=\"sm\">Liquid Temperature<\/td>\n<td data-col-size=\"sm\" data-start=\"2143\" data-end=\"2157\">Up to 80\u00b0C<\/td>\n<\/tr>\n<tr data-start=\"2158\" data-end=\"2190\">\n<td data-start=\"2158\" data-end=\"2177\" data-col-size=\"sm\">Working Pressure<\/td>\n<td data-start=\"2177\" data-end=\"2190\" data-col-size=\"sm\">\u22641.75 MPa<\/td>\n<\/tr>\n<tr data-start=\"2191\" data-end=\"2226\">\n<td data-start=\"2191\" data-end=\"2215\" data-col-size=\"sm\">Insulation Resistance<\/td>\n<td data-start=\"2215\" data-end=\"2226\" data-col-size=\"sm\">&gt;100 M\u03a9<\/td>\n<\/tr>\n<tr data-start=\"2227\" data-end=\"2266\">\n<td data-start=\"2227\" data-end=\"2243\" data-col-size=\"sm\">Body Material<\/td>\n<td data-start=\"2243\" data-end=\"2266\" data-col-size=\"sm\">Engineering Plastic<\/td>\n<\/tr>\n<tr data-start=\"2267\" data-end=\"2291\">\n<td data-start=\"2267\" data-end=\"2276\" data-col-size=\"sm\">Weight<\/td>\n<td data-start=\"2276\" data-end=\"2291\" data-col-size=\"sm\">Approx. 30g<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<hr data-start=\"2398\" data-end=\"2401\" \/>\n<h1 data-section-id=\"16w5cox\" data-start=\"2403\" data-end=\"2422\">Pin Configuration<\/h1>\n<div class=\"TyagGW_tableContainer\">\n<div class=\"group TyagGW_tableWrapper flex flex-col-reverse w-fit\" tabindex=\"-1\">\n<table class=\"w-fit min-w-(--thread-content-width)\" data-start=\"2424\" data-end=\"2560\">\n<thead data-start=\"2424\" data-end=\"2449\">\n<tr data-start=\"2424\" data-end=\"2449\">\n<th class=\"last:pe-10\" data-start=\"2424\" data-end=\"2437\" data-col-size=\"sm\">Wire Color<\/th>\n<th class=\"last:pe-10\" data-start=\"2437\" data-end=\"2449\" data-col-size=\"sm\">Function<\/th>\n<\/tr>\n<\/thead>\n<tbody data-start=\"2476\" data-end=\"2560\">\n<tr data-start=\"2476\" data-end=\"2505\">\n<td data-start=\"2476\" data-end=\"2482\" data-col-size=\"sm\">Red<\/td>\n<td data-start=\"2482\" data-end=\"2505\" data-col-size=\"sm\">VCC (+3.5V to +24V)<\/td>\n<\/tr>\n<tr data-start=\"2506\" data-end=\"2521\">\n<td data-start=\"2506\" data-end=\"2514\" data-col-size=\"sm\">Black<\/td>\n<td data-start=\"2514\" data-end=\"2521\" data-col-size=\"sm\">GND<\/td>\n<\/tr>\n<tr data-start=\"2522\" data-end=\"2560\">\n<td data-start=\"2522\" data-end=\"2537\" data-col-size=\"sm\">Yellow\/Green<\/td>\n<td data-col-size=\"sm\" data-start=\"2537\" data-end=\"2560\">Pulse Signal Output<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<hr data-start=\"2562\" data-end=\"2565\" \/>\n<h1 data-section-id=\"c3mln3\" data-start=\"2567\" data-end=\"2581\">Applications<\/h1>\n<ul data-start=\"2583\" data-end=\"2907\">\n<li data-section-id=\"4l3s3\" data-start=\"2583\" data-end=\"2606\">Water Flow Monitoring<\/li>\n<li data-section-id=\"1xnunoc\" data-start=\"2607\" data-end=\"2627\">Smart Water Meters<\/li>\n<li data-section-id=\"16bsb0y\" data-start=\"2628\" data-end=\"2645\">Coffee Machines<\/li>\n<li data-section-id=\"160myun\" data-start=\"2646\" data-end=\"2664\">Water Dispensers<\/li>\n<li data-section-id=\"ft0xp1\" data-start=\"2665\" data-end=\"2685\">RO Water Purifiers<\/li>\n<li data-section-id=\"oddezd\" data-start=\"2686\" data-end=\"2716\">Automatic Irrigation Systems<\/li>\n<li data-section-id=\"mb338\" data-start=\"2717\" data-end=\"2745\">Liquid Dispensing Machines<\/li>\n<li data-section-id=\"17og4a8\" data-start=\"2746\" data-end=\"2769\">Industrial Automation<\/li>\n<li data-section-id=\"l5q5vc\" data-start=\"2770\" data-end=\"2787\">Home Automation<\/li>\n<li data-section-id=\"18mu96k\" data-start=\"2788\" data-end=\"2802\">IoT Projects<\/li>\n<li data-section-id=\"1jcmd8k\" data-start=\"2803\" data-end=\"2821\">Arduino Projects<\/li>\n<li data-section-id=\"2la6h\" data-start=\"2822\" data-end=\"2838\">ESP32 Projects<\/li>\n<li data-section-id=\"1a4jiu1\" data-start=\"2839\" data-end=\"2862\">Raspberry Pi Projects<\/li>\n<li data-section-id=\"labcvh\" data-start=\"2863\" data-end=\"2880\">DIY Electronics<\/li>\n<li data-section-id=\"izpsny\" data-start=\"2881\" data-end=\"2907\">Cooling Water Monitoring<\/li>\n<\/ul>\n<hr data-start=\"2909\" data-end=\"2912\" \/>\n<h1 data-section-id=\"hg9dub\" data-start=\"2914\" data-end=\"2932\">Package Includes<\/h1>\n<ul data-start=\"2934\" data-end=\"2965\">\n<li data-section-id=\"19d4f1n\" data-start=\"2934\" data-end=\"2965\">1 \u00d7 YF-S401 Water Flow Sensor<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The <strong data-start=\"165\" data-end=\"194\">YF-S401 Water Flow Sensor<\/strong> is a compact Hall-effect flow meter designed to measure the flow rate and total volume of clean water. It generates pulse signals proportional to water flow, making it ideal for Arduino, ESP32, Raspberry Pi, automation, coffee machines, water dispensers, and DIY electronics projects<\/p>\n","protected":false},"featured_media":1352,"comment_status":"open","ping_status":"closed","template":"","meta":[],"product_cat":[64],"product_tag":[307,319,314,311,318,312,315,317,310,313,316,308,309],"class_list":["post-1058","product","type-product","status-publish","has-post-thumbnail","product_cat-flow-sensors","product_tag-capkit-electronics","product_tag-coffee-machine-sensor","product_tag-esp32-flow-sensor","product_tag-hall-effect-flow-sensor","product_tag-irrigation-sensor","product_tag-liquid-flow-meter","product_tag-raspberry-pi-water-sensor","product_tag-smart-water-meter","product_tag-water-flow-sensor","product_tag-water-meter-sensor","product_tag-water-monitoring-sensor","product_tag-yf-s401","product_tag-yfs401","first","instock","taxable","shipping-taxable","purchasable","product-type-simple","col-xs-6 col-sm-4","col-md-3 col-lg-3","un-4-cols"],"_links":{"self":[{"href":"https:\/\/capkit.in\/index.php?rest_route=\/wp\/v2\/product\/1058","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/capkit.in\/index.php?rest_route=\/wp\/v2\/product"}],"about":[{"href":"https:\/\/capkit.in\/index.php?rest_route=\/wp\/v2\/types\/product"}],"replies":[{"embeddable":true,"href":"https:\/\/capkit.in\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1058"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/capkit.in\/index.php?rest_route=\/wp\/v2\/media\/1352"}],"wp:attachment":[{"href":"https:\/\/capkit.in\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1058"}],"wp:term":[{"taxonomy":"product_cat","embeddable":true,"href":"https:\/\/capkit.in\/index.php?rest_route=%2Fwp%2Fv2%2Fproduct_cat&post=1058"},{"taxonomy":"product_tag","embeddable":true,"href":"https:\/\/capkit.in\/index.php?rest_route=%2Fwp%2Fv2%2Fproduct_tag&post=1058"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}