{
 "version": "2.2",
 "instance": {
  "sbsform20f_2025.htm": {
   "nsprefix": "sbs",
   "nsuri": "http://sabesp.com.br/20251231",
   "dts": {
    "schema": {
     "local": [
      "sbs-20251231.xsd"
     ],
     "remote": [
      "http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xl-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xlink-2003-12-31.xsd",
      "http://www.xbrl.org/2005/xbrldt-2005.xsd",
      "http://www.xbrl.org/2006/ref-2006-02-27.xsd",
      "http://www.xbrl.org/dtr/type/nonNumeric-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/negated-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/net-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/reference-2009-12-16.xsd",
      "https://www.xbrl.org/2020/extensible-enumerations-2.0.xsd",
      "https://www.xbrl.org/dtr/type/2020-01-21/types.xsd",
      "https://www.xbrl.org/dtr/type/2022-03-31/types.xsd",
      "https://xbrl.fasb.org/srt/2024/elts/srt-2024.xsd",
      "https://xbrl.fasb.org/srt/2024/elts/srt-roles-2024.xsd",
      "https://xbrl.fasb.org/srt/2024/elts/srt-types-2024.xsd",
      "https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd",
      "https://xbrl.fasb.org/us-gaap/2024/elts/us-roles-2024.xsd",
      "https://xbrl.fasb.org/us-gaap/2024/elts/us-types-2024.xsd",
      "https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/dimensions/rol_full_ifrs-dim_2024-03-27.xsd",
      "https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd",
      "https://xbrl.org/2020/extensible-enumerations-2.0.xsd",
      "https://xbrl.sec.gov/country/2024/country-2024.xsd",
      "https://xbrl.sec.gov/cyd/2024/cyd-2024.xsd",
      "https://xbrl.sec.gov/dei/2024/dei-2024.xsd",
      "https://xbrl.sec.gov/ecd/2024/ecd-2024.xsd",
      "https://xbrl.sec.gov/stpr/2024/stpr-2024.xsd"
     ]
    },
    "calculationLink": {
     "local": [
      "sbs-20251231_cal.xml"
     ]
    },
    "definitionLink": {
     "local": [
      "sbs-20251231_def.xml"
     ],
     "remote": [
      "https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/dimensions/dim_full_ifrs_2024-03-27_role-995000.xml"
     ]
    },
    "labelLink": {
     "local": [
      "sbs-20251231_lab.xml"
     ]
    },
    "presentationLink": {
     "local": [
      "sbs-20251231_pre.xml"
     ]
    },
    "inline": {
     "local": [
      "sbsform20f_2025.htm"
     ]
    }
   },
   "keyStandard": 310,
   "keyCustom": 448,
   "axisStandard": 31,
   "axisCustom": 9,
   "memberStandard": 26,
   "memberCustom": 298,
   "hidden": {
    "total": 545,
    "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full": 229,
    "http://sabesp.com.br/20251231": 311,
    "http://xbrl.sec.gov/dei/2024": 5
   },
   "contextCount": 935,
   "entityCount": 1,
   "segmentCount": 343,
   "elementCount": 1357,
   "unitCount": 8,
   "baseTaxonomies": {
    "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full": 1851,
    "http://xbrl.sec.gov/dei/2024": 43,
    "http://xbrl.sec.gov/cyd/2024": 10,
    "http://xbrl.sec.gov/ecd/2024": 1
   },
   "report": {
    "R1": {
     "role": "http://sabesp.com.br/role/Cover",
     "longName": "00000001 - Document - Cover",
     "shortName": "Cover",
     "isDefault": "true",
     "groupType": "document",
     "subGroupType": "",
     "menuCat": "Cover",
     "order": "1",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "dei:DocumentType",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "b",
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "dei:DocumentType",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "b",
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R2": {
     "role": "http://sabesp.com.br/role/StatementsOfFinancialPosition",
     "longName": "00000002 - Statement - Consolidated Statements of Financial Position",
     "shortName": "Consolidated Statements of Financial Position",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "2",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:CashAndCashEquivalents",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:DerivativeFinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R3": {
     "role": "http://sabesp.com.br/role/StatementsOfIncome",
     "longName": "00000003 - Statement - Consolidated Statements of Income",
     "shortName": "Consolidated Statements of Income",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "3",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:Revenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:GrossProfit",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R4": {
     "role": "http://sabesp.com.br/role/StatementsOfComprehensiveIncome",
     "longName": "00000004 - Statement - Consolidated Statements of Comprehensive Income",
     "shortName": "Consolidated Statements of Comprehensive Income",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "4",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:ProfitLoss",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ItemsWhichWillBeSubsequentlyReclassifiedToIncomeStatement",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R5": {
     "role": "http://sabesp.com.br/role/StatementOfChangesInEquity",
     "longName": "00000005 - Statement - Consolidated Statement of Changes in Equity",
     "shortName": "Consolidated Statement of Changes in Equity",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "5",
     "firstAnchor": {
      "contextRef": "AsOf2022-12-31_ifrs-full_IssuedCapitalMember",
      "name": "ifrs-full:Equity",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "p",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2022-12-31_ifrs-full_IssuedCapitalMember",
      "name": "ifrs-full:Equity",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "p",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R6": {
     "role": "http://sabesp.com.br/role/StatementsOfCashFlows",
     "longName": "00000006 - Statement - Consolidated Statements of Cash Flows",
     "shortName": "Consolidated Statements of Cash Flows",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "6",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ProfitBeforeIncomeTaxAndSocialContribution",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ProfitBeforeIncomeTaxAndSocialContribution",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R7": {
     "role": "http://xbrl.sec.gov/ecd/role/InsiderTradingPoliciesProc",
     "longName": "995447 - Disclosure - Insider Trading Policies and Procedures",
     "shortName": "Insider Trading Policies and Procedures",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "7",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ecd:InsiderTrdPoliciesProcAdoptedFlag",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ecd:InsiderTrdPoliciesProcAdoptedFlag",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R8": {
     "role": "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure",
     "longName": "995550 - Disclosure - Cybersecurity Risk Management and Strategy Disclosure",
     "shortName": "Cybersecurity Risk Management and Strategy Disclosure",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "8",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "cyd:CybersecurityRiskManagementProcessesForAssessingIdentifyingAndManagingThreatsTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "cyd:CybersecurityRiskManagementProcessesForAssessingIdentifyingAndManagingThreatsTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "p",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R9": {
     "role": "http://sabesp.com.br/role/Operations",
     "longName": "999014 - Disclosure - Operations",
     "shortName": "Operations",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "9",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOperationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOperationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R10": {
     "role": "http://sabesp.com.br/role/BasisOfPreparationAndPresentationOfFinancialStatements",
     "longName": "999015 - Disclosure - Basis of preparation and presentation of the financial statements",
     "shortName": "Basis of preparation and presentation of the financial statements",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "10",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R11": {
     "role": "http://sabesp.com.br/role/SummaryOfMaterialAccountingPolicyInformation",
     "longName": "999016 - Disclosure - Summary of material accounting policy information",
     "shortName": "Summary of material accounting policy information",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "11",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R12": {
     "role": "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosures",
     "longName": "999017 - Disclosure - Changes in accounting practices and disclosures",
     "shortName": "Changes in accounting practices and disclosures",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "12",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R13": {
     "role": "http://sabesp.com.br/role/RiskManagement",
     "longName": "999018 - Disclosure - Risk management",
     "shortName": "Risk management",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "13",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfRiskManagementExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfRiskManagementExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R14": {
     "role": "http://sabesp.com.br/role/SignificantAccountingEstimatesAndJudgments",
     "longName": "999019 - Disclosure - Significant accounting estimates and judgments",
     "shortName": "Significant accounting estimates and judgments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "14",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfChangesInAccountingEstimatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfChangesInAccountingEstimatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R15": {
     "role": "http://sabesp.com.br/role/CashAndCashEquivalents",
     "longName": "999020 - Disclosure - Cash and cash equivalents",
     "shortName": "Cash and cash equivalents",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "15",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R16": {
     "role": "http://sabesp.com.br/role/FinancialInvestments",
     "longName": "999021 - Disclosure - Financial investments",
     "shortName": "Financial investments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "16",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R17": {
     "role": "http://sabesp.com.br/role/RestrictedCash",
     "longName": "999022 - Disclosure - Restricted cash",
     "shortName": "Restricted cash",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "17",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfRestrictedCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfRestrictedCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R18": {
     "role": "http://sabesp.com.br/role/TradeReceivables",
     "longName": "999023 - Disclosure - Trade receivables",
     "shortName": "Trade receivables",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "18",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R19": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactions",
     "longName": "999024 - Disclosure - Related-party balances and transactions",
     "shortName": "Related-party balances and transactions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "19",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfRelatedPartyExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfRelatedPartyExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R20": {
     "role": "http://sabesp.com.br/role/Investments",
     "longName": "999025 - Disclosure - Investments",
     "shortName": "Investments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "20",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R21": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssets",
     "longName": "999026 - Disclosure - Contract assets and other concession assets",
     "shortName": "Contract assets and other concession assets",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "21",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R22": {
     "role": "http://sabesp.com.br/role/IntangibleAssets",
     "longName": "999027 - Disclosure - Intangible assets",
     "shortName": "Intangible assets",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "22",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfIntangibleAssetExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfIntangibleAssetExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R23": {
     "role": "http://sabesp.com.br/role/FinancialAssetOfConcession",
     "longName": "999028 - Disclosure - Financial asset of the concession",
     "shortName": "Financial asset of the concession",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "23",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R24": {
     "role": "http://sabesp.com.br/role/PropertyPlantAndEquipment",
     "longName": "999029 - Disclosure - Property, plant, and equipment",
     "shortName": "Property, plant, and equipment",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "24",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R25": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancing",
     "longName": "999030 - Disclosure - Borrowings and financing",
     "shortName": "Borrowings and financing",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "25",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R26": {
     "role": "http://sabesp.com.br/role/FinancialInstruments",
     "longName": "999031 - Disclosure - Financial instruments",
     "shortName": "Financial instruments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "26",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R27": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactions",
     "longName": "999032 - Disclosure - Derivative financial instruments and hedging transactions",
     "shortName": "Derivative financial instruments and hedging transactions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "27",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R28": {
     "role": "http://sabesp.com.br/role/TaxesAndContributions",
     "longName": "999033 - Disclosure - Taxes and Contributions",
     "shortName": "Taxes and Contributions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "28",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R29": {
     "role": "http://sabesp.com.br/role/DeferredPiscofinsTaxes",
     "longName": "999034 - Disclosure - Deferred PIS/Cofins taxes",
     "shortName": "Deferred PIS/Cofins taxes",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "29",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R30": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributions",
     "longName": "999035 - Disclosure - Deferred taxes and contributions",
     "shortName": "Deferred taxes and contributions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "30",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R31": {
     "role": "http://sabesp.com.br/role/Provisions",
     "longName": "999036 - Disclosure - Provisions",
     "shortName": "Provisions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "31",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfProvisionExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfProvisionExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R32": {
     "role": "http://sabesp.com.br/role/LaborAndSocialObligations",
     "longName": "999037 - Disclosure - Labor and social obligations",
     "shortName": "Labor and social obligations",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "32",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfEmployeeBenefitExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfEmployeeBenefitExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R33": {
     "role": "http://sabesp.com.br/role/PensionPlanObligations",
     "longName": "999038 - Disclosure - Pension plan obligations",
     "shortName": "Pension plan obligations",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "33",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R34": {
     "role": "http://sabesp.com.br/role/ServicesPayable",
     "longName": "999039 - Disclosure - Services payable",
     "shortName": "Services payable",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "34",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R35": {
     "role": "http://sabesp.com.br/role/Equity",
     "longName": "999040 - Disclosure - Equity",
     "shortName": "Equity",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "35",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfIssuedCapitalsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfIssuedCapitalsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R36": {
     "role": "http://sabesp.com.br/role/EarningsPerShare",
     "longName": "999041 - Disclosure - Earnings per share",
     "shortName": "Earnings per share",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "36",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfEarningsPerShareExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfEarningsPerShareExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R37": {
     "role": "http://sabesp.com.br/role/OperatingSegmentInformation",
     "longName": "999042 - Disclosure - Operating segment information",
     "shortName": "Operating segment information",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "37",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOperatingSegmentExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOperatingSegmentExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R38": {
     "role": "http://sabesp.com.br/role/OperatingRevenue",
     "longName": "999043 - Disclosure - Operating revenue",
     "shortName": "Operating revenue",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "38",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfRevenuesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfRevenuesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R39": {
     "role": "http://sabesp.com.br/role/OperatingCostsAndExpenses",
     "longName": "999044 - Disclosure - Operating costs and expenses",
     "shortName": "Operating costs and expenses",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "39",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R40": {
     "role": "http://sabesp.com.br/role/FinancialIncomeexpenseNet",
     "longName": "999045 - Disclosure - Financial income/(expense), net",
     "shortName": "Financial income/(expense), net",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "40",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R41": {
     "role": "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNet",
     "longName": "999046 - Disclosure - Other operating income (expenses), net",
     "shortName": "Other operating income (expenses), net",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "41",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R42": {
     "role": "http://sabesp.com.br/role/Commitments",
     "longName": "999047 - Disclosure - Commitments",
     "shortName": "Commitments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "42",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfCommitmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfCommitmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R43": {
     "role": "http://sabesp.com.br/role/SupplementalCashFlowInformation",
     "longName": "999048 - Disclosure - Supplemental cash flow information",
     "shortName": "Supplemental cash flow information",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "43",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R44": {
     "role": "http://sabesp.com.br/role/EventsAfterReportingPeriod",
     "longName": "999049 - Disclosure - Events after the reporting period",
     "shortName": "Events after the reporting period",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "44",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfEventsAfterReportingPeriodExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfEventsAfterReportingPeriodExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R45": {
     "role": "http://sabesp.com.br/role/SummaryOfMaterialAccountingPolicyInformationPolicies",
     "longName": "999050 - Disclosure - Summary of material accounting policy information (Policies)",
     "shortName": "Summary of material accounting policy information (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "45",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfBasisOfConsolidationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfBasisOfConsolidationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R46": {
     "role": "http://sabesp.com.br/role/CashAndCashEquivalentsPolicies",
     "longName": "999051 - Disclosure - Cash and cash equivalents (Policies)",
     "shortName": "Cash and cash equivalents (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "46",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForRestrictedCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForRestrictedCashAndCashEquivalentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R47": {
     "role": "http://sabesp.com.br/role/FinancialInvestmentsPolicies",
     "longName": "999052 - Disclosure - Financial investments (Policies)",
     "shortName": "Financial investments (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "47",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForInvestmentInAssociates",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForInvestmentInAssociates",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R48": {
     "role": "http://sabesp.com.br/role/TradeReceivablesPolicies",
     "longName": "999053 - Disclosure - Trade receivables (Policies)",
     "shortName": "Trade receivables (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "48",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForTradeAndOtherReceivablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForTradeAndOtherReceivablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R49": {
     "role": "http://sabesp.com.br/role/InvestmentsPolicies",
     "longName": "999054 - Disclosure - Investments (Policies)",
     "shortName": "Investments (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "49",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForInvestmentsInJointVentures",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForInvestmentsInJointVentures",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R50": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsPolicies",
     "longName": "999055 - Disclosure - Contract assets and other concession assets (Policies)",
     "shortName": "Contract assets and other concession assets (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "50",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForContingentLiabilitiesAndContingentAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForContingentLiabilitiesAndContingentAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R51": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsPolicies",
     "longName": "999056 - Disclosure - Intangible assets (Policies)",
     "shortName": "Intangible assets (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "51",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R52": {
     "role": "http://sabesp.com.br/role/FinancialAssetOfConcessionPolicies",
     "longName": "999057 - Disclosure - Financial asset of the concession (Policies)",
     "shortName": "Financial asset of the concession (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "52",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R53": {
     "role": "http://sabesp.com.br/role/PropertyPlantAndEquipmentPolicies",
     "longName": "999058 - Disclosure - Property, plant, and equipment (Policies)",
     "shortName": "Property, plant, and equipment (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "53",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForPropertyPlantAndEquipmentExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForPropertyPlantAndEquipmentExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R54": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingPolicies",
     "longName": "999059 - Disclosure - Borrowings and financing (Policies)",
     "shortName": "Borrowings and financing (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "54",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForBorrowingsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForBorrowingsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R55": {
     "role": "http://sabesp.com.br/role/FinancialInstrumentsPolicies",
     "longName": "999060 - Disclosure - Financial instruments (Policies)",
     "shortName": "Financial instruments (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "55",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R56": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsPolicies",
     "longName": "999061 - Disclosure - Derivative financial instruments and hedging transactions (Policies)",
     "shortName": "Derivative financial instruments and hedging transactions (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "56",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDerivativeFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDerivativeFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R57": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsPolicies",
     "longName": "999062 - Disclosure - Deferred taxes and contributions (Policies)",
     "shortName": "Deferred taxes and contributions (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "57",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R58": {
     "role": "http://sabesp.com.br/role/ProvisionsPolicies",
     "longName": "999063 - Disclosure - Provisions (Policies)",
     "shortName": "Provisions (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "58",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForProvisionsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForProvisionsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R59": {
     "role": "http://sabesp.com.br/role/LaborAndSocialObligationsPolicies",
     "longName": "999064 - Disclosure - Labor and social obligations (Policies)",
     "shortName": "Labor and social obligations (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "59",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfAccountingPolicyForLaborAndSocialObligationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfAccountingPolicyForLaborAndSocialObligationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R60": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsPolicies",
     "longName": "999065 - Disclosure - Pension plan obligations (Policies)",
     "shortName": "Pension plan obligations (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "60",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfAccountingPolicyForPensionPlanObligationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DescriptionOfAccountingPolicyForPensionPlanObligationsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R61": {
     "role": "http://sabesp.com.br/role/EquityPolicies",
     "longName": "999066 - Disclosure - Equity (Policies)",
     "shortName": "Equity (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "61",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDividendsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForDividendsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R62": {
     "role": "http://sabesp.com.br/role/OperatingSegmentInformationPolicies",
     "longName": "999067 - Disclosure - Operating segment information (Policies)",
     "shortName": "Operating segment information (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "62",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForSegmentReportingExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForSegmentReportingExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R63": {
     "role": "http://sabesp.com.br/role/OperatingRevenuePolicies",
     "longName": "999068 - Disclosure - Operating revenue (Policies)",
     "shortName": "Operating revenue (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "63",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForRecognitionOfRevenue",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForRecognitionOfRevenue",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R64": {
     "role": "http://sabesp.com.br/role/FinancialIncomeexpenseNetPolicies",
     "longName": "999069 - Disclosure - Financial income/(expense), net (Policies)",
     "shortName": "Financial income/(expense), net (Policies)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "64",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinanceIncomeAndCostsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfAccountingPolicyForFinanceIncomeAndCostsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R65": {
     "role": "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresTables",
     "longName": "999070 - Disclosure - Changes in accounting practices and disclosures (Tables)",
     "shortName": "Changes in accounting practices and disclosures (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "65",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R66": {
     "role": "http://sabesp.com.br/role/RiskManagementTables",
     "longName": "999071 - Disclosure - Risk management (Tables)",
     "shortName": "Risk management (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "66",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfExposureToExchangeRiskTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfExposureToExchangeRiskTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R67": {
     "role": "http://sabesp.com.br/role/CashAndCashEquivalentsTables",
     "longName": "999072 - Disclosure - Cash and cash equivalents (Tables)",
     "shortName": "Cash and cash equivalents (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "67",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfCashAndCashEquivalentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfCashAndCashEquivalentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R68": {
     "role": "http://sabesp.com.br/role/FinancialInvestmentsTables",
     "longName": "999073 - Disclosure - Financial investments (Tables)",
     "shortName": "Financial investments (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "68",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialInvestmentsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialInvestmentsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R69": {
     "role": "http://sabesp.com.br/role/TradeReceivablesTables",
     "longName": "999074 - Disclosure - Trade receivables (Tables)",
     "shortName": "Trade receivables (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "69",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialPositionTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialPositionTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R70": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsTables",
     "longName": "999075 - Disclosure - Related-party balances and transactions (Tables)",
     "shortName": "Related-party balances and transactions (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "70",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R71": {
     "role": "http://sabesp.com.br/role/InvestmentsTables",
     "longName": "999076 - Disclosure - Investments (Tables)",
     "shortName": "Investments (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "71",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfInvesteesFinancialStatementsAndEquityInterestTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfInvesteesFinancialStatementsAndEquityInterestTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R72": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsTables",
     "longName": "999077 - Disclosure - Contract assets and other concession assets (Tables)",
     "shortName": "Contract assets and other concession assets (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "72",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfContractAssetsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfContractAssetsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R73": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsTables",
     "longName": "999078 - Disclosure - Intangible assets (Tables)",
     "shortName": "Intangible assets (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "73",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfFinancialPositionDetailsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfFinancialPositionDetailsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R74": {
     "role": "http://sabesp.com.br/role/FinancialAssetOfConcessionTables",
     "longName": "999079 - Disclosure - Financial asset of the concession (Tables)",
     "shortName": "Financial asset of the concession (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "74",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialAssetResultingFromConcessionAgreementTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialAssetResultingFromConcessionAgreementTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R75": {
     "role": "http://sabesp.com.br/role/PropertyPlantAndEquipmentTables",
     "longName": "999080 - Disclosure - Property, plant, and equipment (Tables)",
     "shortName": "Property, plant, and equipment (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "75",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfPropertyPlantAndEquipmentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfPropertyPlantAndEquipmentTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R76": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingTables",
     "longName": "999081 - Disclosure - Borrowings and financing (Tables)",
     "shortName": "Borrowings and financing (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "76",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfBorrowingsAndFinancingOutstandingTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfBorrowingsAndFinancingOutstandingTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R77": {
     "role": "http://sabesp.com.br/role/FinancialInstrumentsTables",
     "longName": "999082 - Disclosure - Financial instruments (Tables)",
     "shortName": "Financial instruments (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "77",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfReclassificationOfFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DisclosureOfReclassificationOfFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R78": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsTables",
     "longName": "999083 - Disclosure - Derivative financial instruments and hedging transactions (Tables)",
     "shortName": "Derivative financial instruments and hedging transactions (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "78",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R79": {
     "role": "http://sabesp.com.br/role/TaxesAndContributionsTables",
     "longName": "999084 - Disclosure - Taxes and Contributions (Tables)",
     "shortName": "Taxes and Contributions (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "79",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfCurrentTaxAssetsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfCurrentTaxAssetsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R80": {
     "role": "http://sabesp.com.br/role/DeferredPiscofinsTaxesTables",
     "longName": "999085 - Disclosure - Deferred PIS/Cofins taxes (Tables)",
     "shortName": "Deferred PIS/Cofins taxes (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "80",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfDeferredPISAndCofinsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfDeferredPISAndCofinsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R81": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsTables",
     "longName": "999086 - Disclosure - Deferred taxes and contributions (Tables)",
     "shortName": "Deferred taxes and contributions (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "81",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfDeferredTaxesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfDeferredTaxesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R82": {
     "role": "http://sabesp.com.br/role/ProvisionsTables",
     "longName": "999087 - Disclosure - Provisions (Tables)",
     "shortName": "Provisions (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "82",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R83": {
     "role": "http://sabesp.com.br/role/LaborAndSocialObligationsTables",
     "longName": "999088 - Disclosure - Labor and social obligations (Tables)",
     "shortName": "Labor and social obligations (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "83",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfEmployeesBenefitsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfEmployeesBenefitsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R84": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsTables",
     "longName": "999089 - Disclosure - Pension plan obligations (Tables)",
     "shortName": "Pension plan obligations (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "84",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfPensionPlanBenefitsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfPensionPlanBenefitsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R85": {
     "role": "http://sabesp.com.br/role/ServicesPayableTables",
     "longName": "999090 - Disclosure - Services payable (Tables)",
     "shortName": "Services payable (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "85",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfServicesPayableTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfServicesPayableTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R86": {
     "role": "http://sabesp.com.br/role/EquityTables",
     "longName": "999091 - Disclosure - Equity (Tables)",
     "shortName": "Equity (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "86",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfShareCapitalTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfShareCapitalTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R87": {
     "role": "http://sabesp.com.br/role/EarningsPerShareTables",
     "longName": "999092 - Disclosure - Earnings per share (Tables)",
     "shortName": "Earnings per share (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "87",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfEarningsPerShareBasicAndDilutedTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfEarningsPerShareExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SummaryOfEarningsPerShareBasicAndDilutedTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfEarningsPerShareExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R88": {
     "role": "http://sabesp.com.br/role/OperatingSegmentInformationTables",
     "longName": "999093 - Disclosure - Operating segment information (Tables)",
     "shortName": "Operating segment information (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "88",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfOperatingSegmentInformationTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfOperatingSegmentInformationTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R89": {
     "role": "http://sabesp.com.br/role/OperatingRevenueTables",
     "longName": "999094 - Disclosure - Operating revenue (Tables)",
     "shortName": "Operating revenue (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "89",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R90": {
     "role": "http://sabesp.com.br/role/OperatingCostsAndExpensesTables",
     "longName": "999095 - Disclosure - Operating costs and expenses (Tables)",
     "shortName": "Operating costs and expenses (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "90",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SchdeuleOfExpensesByNatureTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SchdeuleOfExpensesByNatureTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R91": {
     "role": "http://sabesp.com.br/role/FinancialIncomeexpenseNetTables",
     "longName": "999096 - Disclosure - Financial income/(expense), net (Tables)",
     "shortName": "Financial income/(expense), net (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "91",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialIncomeExpensesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfFinancialIncomeExpensesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R92": {
     "role": "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetTables",
     "longName": "999097 - Disclosure - Other operating income (expenses), net (Tables)",
     "shortName": "Other operating income (expenses), net (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "92",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfOtherOperatingIncomeExpensesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfOtherOperatingIncomeExpensesTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R93": {
     "role": "http://sabesp.com.br/role/CommitmentsTables",
     "longName": "999098 - Disclosure - Commitments (Tables)",
     "shortName": "Commitments (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "93",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfCommitmentsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCommitmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfCommitmentsTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "ifrs-full:DisclosureOfCommitmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R94": {
     "role": "http://sabesp.com.br/role/SupplementalCashFlowInformationTables",
     "longName": "999099 - Disclosure - Supplemental cash flow information (Tables)",
     "shortName": "Supplemental cash flow information (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "94",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfSupplementalCashFlowInformationTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ScheduleOfSupplementalCashFlowInformationTableTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R95": {
     "role": "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails",
     "longName": "999100 - Disclosure - Changes in accounting practices and disclosures (Details)",
     "shortName": "Changes in accounting practices and disclosures (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "95",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AmendmentsToIFRS9Member",
      "name": "ifrs-full:TitleOfInitiallyAppliedIFRS",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "p",
       "td",
       "tr",
       "table",
       "ifrs-full:DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
       "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AmendmentsToIFRS9Member",
      "name": "ifrs-full:TitleOfInitiallyAppliedIFRS",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "p",
       "td",
       "tr",
       "table",
       "ifrs-full:DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
       "sbs:DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R96": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails",
     "longName": "999101 - Disclosure - Risk Management (Details)",
     "shortName": "Risk Management (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "96",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:MaximumExposureToExchangeRisk",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfExposureToExchangeRiskTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:MaximumExposureToExchangeRisk",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfExposureToExchangeRiskTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R97": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails1",
     "longName": "999102 - Disclosure - Risk Management (Details 1)",
     "shortName": "Risk Management (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "97",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31_custom_CurrencyOfUSDMember",
      "name": "sbs:ClosingForeignExchangeRate1",
      "unitRef": "BRLPShares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfIncreaseDecreaseInExchangeRateTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_CurrencyOfUSDMember",
      "name": "sbs:ClosingForeignExchangeRate1",
      "unitRef": "BRLPShares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfIncreaseDecreaseInExchangeRateTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R98": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails2",
     "longName": "999103 - Disclosure - Risk Management (Details 2)",
     "shortName": "Risk Management (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "98",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsAndFinancing",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfBorrowingsAndFinancingSubjectToDifferentInflationAdjustmentIndicesTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsAndFinancing",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfBorrowingsAndFinancingSubjectToDifferentInflationAdjustmentIndicesTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R99": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails3",
     "longName": "999104 - Disclosure - Risk Management (Details 3)",
     "shortName": "Risk Management (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "99",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:FinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_ifrs-full_InterestRateRiskMember",
      "name": "ifrs-full:FinancialLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfSensitivityAnalysisOnInterestRateRiskTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R100": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails4",
     "longName": "999105 - Disclosure - Risk Management (Details 4)",
     "shortName": "Risk Management (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "100",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingAndFinancing",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfLiquidityRiskExplanatory",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingAndFinancing",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfLiquidityRiskExplanatory",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R101": {
     "role": "http://sabesp.com.br/role/RiskManagementDetails5",
     "longName": "999106 - Disclosure - Risk Management (Details 5)",
     "shortName": "Risk Management (Details 5)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "101",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Borrowings",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCapitalManagementTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:CashAndCashEquivalents1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCapitalManagementTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R102": {
     "role": "http://sabesp.com.br/role/RiskManagementDetailsNarrative",
     "longName": "999107 - Disclosure - Risk management (Details Narrative)",
     "shortName": "Risk management (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "102",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:MaximumExposureToCreditRisk",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "span",
       "p",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:MaximumExposureToCreditRisk",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "span",
       "p",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R103": {
     "role": "http://sabesp.com.br/role/CashAndCashEquivalentsDetails",
     "longName": "999108 - Disclosure - Cash and cash equivalents (Details)",
     "shortName": "Cash and cash equivalents (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "103",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Cash",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCashAndCashEquivalentTableTextBlock",
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Cash",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCashAndCashEquivalentTableTextBlock",
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R104": {
     "role": "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
     "longName": "999109 - Disclosure - Cash and cash equivalents (Details Narrative)",
     "shortName": "Cash and cash equivalents (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "104",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:OtherCashAndCashEquivalents",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:OtherCashAndCashEquivalents",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfCashAndCashEquivalentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R105": {
     "role": "http://sabesp.com.br/role/FinancialInvestmentsDetails",
     "longName": "999110 - Disclosure - Financial investments (Details)",
     "shortName": "Financial investments (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "105",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:CurrentFinancialAssetsAtAmortisedCost",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:CurrentFinancialAssetAtAmortisedCost",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialInvestmentsTableTextBlock",
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R106": {
     "role": "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
     "longName": "999111 - Disclosure - Financial investments (Details Narrative)",
     "shortName": "Financial investments (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "106",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:FinancialInvestmentsNonCurrent",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-6",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:FinancialInvestmentsNonCurrent",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-6",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfFinancialAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R107": {
     "role": "http://sabesp.com.br/role/RestrictedCashDetailsNarrative",
     "longName": "999112 - Disclosure - Restricted cash (Details Narrative)",
     "shortName": "Restricted cash (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "107",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:RestrictedCashAndCashEquivalents",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": null
    },
    "R108": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetails",
     "longName": "999113 - Disclosure - Trade receivables (Details)",
     "shortName": "Trade receivables (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "108",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:TradeReceivables",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialPositionTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:AllowanceAccountForCreditLossOfFinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialPositionTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R109": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetails1",
     "longName": "999114 - Disclosure - Trade receivables (Details 1)",
     "shortName": "Trade receivables (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "109",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:TradeReceivables",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialPositionTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_ifrs-full_CurrentMember",
      "name": "ifrs-full:TradeReceivables",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfAgingOfTradeReceivablesTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R110": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetails2",
     "longName": "999115 - Disclosure - Trade receivables (Details 2)",
     "shortName": "Trade receivables (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "110",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:AllowanceAccountForCreditLossesOfFinancialAssets1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfTradeReceivableAllowanceForDoubtfulAccountsTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2023-12-31",
      "name": "sbs:AllowanceAccountForCreditLossesOfFinancialAssets1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfTradeReceivableAllowanceForDoubtfulAccountsTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R111": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetails3",
     "longName": "999116 - Disclosure - Trade receivables (Details 3)",
     "shortName": "Trade receivables (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "111",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:WriteoffsDuringPeriodForBadAndDoubtfulDebtsForThirdPartyTransaction",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfReconciliationOfEstimatedHistoricalLossesOfIncomeTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:WriteoffsDuringPeriodForBadAndDoubtfulDebtsForThirdPartyTransaction",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfReconciliationOfEstimatedHistoricalLossesOfIncomeTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R112": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetails4",
     "longName": "999117 - Disclosure - Trade receivables (Details 4)",
     "shortName": "Trade receivables (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "112",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:JudicialPaymentOrder",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfJudicialBondsTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:JudicialPaymentOrder",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfJudicialBondsTableTextBlock",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R113": {
     "role": "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative",
     "longName": "999118 - Disclosure - Trade receivables (Details Narrative)",
     "shortName": "Trade receivables (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "113",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_NonAdjustingEventMember",
      "name": "sbs:JudicialPaymentReceived",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_NonAdjustingEventMember",
      "name": "sbs:JudicialPaymentReceived",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfTradeAndOtherReceivableExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R114": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
     "longName": "999119 - Disclosure - Related-Party Balances and Transactions (Details)",
     "shortName": "Related-Party Balances and Transactions (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "114",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:AmountsReceivableRelatedPartyTransaction",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:AmountsReceivableRelatedPartyTransaction",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R115": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1",
     "longName": "999120 - Disclosure - Related-Party Balances and Transactions (Details 1)",
     "shortName": "Related-Party Balances and Transactions (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "115",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:Revenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_SanitationServicesMember",
      "name": "ifrs-full:Revenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfLoanAgreementThroughCreditFacilityTableTextBlock",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R116": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails2",
     "longName": "999121 - Disclosure - Related-Party Balances and Transactions (Details 2)",
     "shortName": "Related-Party Balances and Transactions (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "116",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:KeyManagementPersonnelCompensationShorttermEmployeeBenefits",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfTransactionsBetweenRelatedPartiesExplanatory",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:KeyManagementPersonnelCompensationShorttermEmployeeBenefits",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfTransactionsBetweenRelatedPartiesExplanatory",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R117": {
     "role": "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative",
     "longName": "999122 - Disclosure - Related-party balances and transactions (Details Narrative)",
     "shortName": "Related-party balances and transactions (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "117",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:DisputedAmountsReceivable",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:DisputedAmountsReceivable",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfRelatedPartyExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R118": {
     "role": "http://sabesp.com.br/role/InvestmentsDetails",
     "longName": "999123 - Disclosure - Investments (Details)",
     "shortName": "Investments (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "118",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Equity",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:InvestmentAccountedForUsingEquityMethod1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfInvesteesFinancialStatementsAndEquityInterestTableTextBlock",
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R119": {
     "role": "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
     "longName": "999124 - Disclosure - Investments (Details Narrative)",
     "shortName": "Investments (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "119",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:IssuedCapital",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-11-03_custom_SABESPMember",
      "name": "ifrs-full:IssuedCapital",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R120": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails",
     "longName": "999125 - Disclosure - Contract assets and other concession assets (Details)",
     "shortName": "Contract assets and other concession assets (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "120",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:ContractAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfContractAssetsTableTextBlock",
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2023-12-31",
      "name": "ifrs-full:ContractAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfContractAssetsTableTextBlock",
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R121": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1",
     "longName": "999126 - Disclosure - Contract assets and other concession assets (Details 1)",
     "shortName": "Contract assets and other concession assets (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "121",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Inventories",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_ContractAssetMember",
      "name": "ifrs-full:CurrentAdvancesToSuppliers",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfServiceConcessionArrangementsExplanatory",
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R122": {
     "role": "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetailsNarrative",
     "longName": "999127 - Disclosure - Contract assets and other concession assets (Details Narrative)",
     "shortName": "Contract assets and other concession assets (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "122",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:InterestInflationAdjustmentsAndExchangeVariationsCapitalizaedInTheContractAsset",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:InterestInflationAdjustmentsAndExchangeVariationsCapitalizaedInTheContractAsset",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R123": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails",
     "longName": "999128 - Disclosure - Intangible assets (Details)",
     "shortName": "Intangible assets (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "123",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:IntangibleAssetsOtherThanGoodwillCarryingAmountAtCostOfRevaluedAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfFinancialPositionDetailsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:IntangibleAssetsOtherThanGoodwillCarryingAmountAtCostOfRevaluedAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfFinancialPositionDetailsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R124": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails1",
     "longName": "999129 - Disclosure - Intangible assets (Details 1)",
     "shortName": "Intangible assets (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "124",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:IntangibleAssetsOtherThanGoodwill1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SumamryOfChangesInIntangibleAssetsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:AdditionsOtherThanThroughBusinessCombinationsIntangibleAssetOtherThanGoodwill",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SumamryOfChangesInIntangibleAssetsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R125": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails2",
     "longName": "999130 - Disclosure - Intangible assets (Details 2)",
     "shortName": "Intangible assets (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "125",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AltoTieteMember",
      "name": "sbs:AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipAltoTiete",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfIntangibleAssetsRecordedTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AltoTieteMember",
      "name": "sbs:AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipAltoTiete",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfIntangibleAssetsRecordedTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R126": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails3",
     "longName": "999131 - Disclosure - Intangible assets (Details 3)",
     "shortName": "Intangible assets (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "126",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PublicPrivatePartnershipCurrent",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_SaoLourencoMember",
      "name": "sbs:PublicPrivatePartnershipCurrent",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfLiabilitiesAssumedTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R127": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails4",
     "longName": "999132 - Disclosure - Intangible assets (Details 4)",
     "shortName": "Intangible assets (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "127",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:ExpenseByNature",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SchdeuleOfExpensesByNatureTableTextBlock",
       "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_PublicPrivatePartnershipMember",
      "name": "sbs:GeneralSupplies",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfExpensesWithPublicPrivateTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R128": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails5",
     "longName": "999133 - Disclosure - Intangible assets (Details 5)",
     "shortName": "Intangible assets (Details 5)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "128",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:TotalLeasesAndRightOfUse",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfRightOfUseTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:TotalLeasesAndRightOfUse",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfRightOfUseTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R129": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails6",
     "longName": "999134 - Disclosure - Intangible assets (Details 6)",
     "shortName": "Intangible assets (Details 6)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "129",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DepreciationRightofuseAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfIncomeStatementImpactTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:DepreciationRightofuseAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfIncomeStatementImpactTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R130": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails7",
     "longName": "999135 - Disclosure - Intangible assets (Details 7)",
     "shortName": "Intangible assets (Details 7)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "130",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PerformanceAgreementsContractAssetsAndOtherConcessionAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfContractAssetAndInstangibleAssetsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PerformanceAgreementsContractAssetsAndOtherConcessionAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfContractAssetAndInstangibleAssetsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R131": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetails8",
     "longName": "999136 - Disclosure - Intangible assets (Details 8)",
     "shortName": "Intangible assets (Details 8)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "131",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PerformanceAgreementsCurrentLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfObligationsAssumedLiabilitiesTableTeaxtBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PerformanceAgreementsCurrentLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfObligationsAssumedLiabilitiesTableTeaxtBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R132": {
     "role": "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
     "longName": "999137 - Disclosure - Intangible assets (Details Narrative)",
     "shortName": "Intangible assets (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "132",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:IntangibleAssetsOtherThanGoodwill1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SumamryOfChangesInIntangibleAssetsTableTextBlock",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:AmortizationAverageRate",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfIntangibleAssetExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R133": {
     "role": "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails",
     "longName": "999138 - Disclosure - Financial asset of the concession (Details)",
     "shortName": "Financial asset of the concession (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "133",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:FinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2024-12-31_custom_ConcessionAgreementURAE1Member",
      "name": "ifrs-full:FinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialAssetResultingFromConcessionAgreementTableTextBlock",
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R134": {
     "role": "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
     "longName": "999139 - Disclosure - Financial asset of the concession (Details Narrative)",
     "shortName": "Financial asset of the concession (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "134",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:AverageEffectiveTaxRate",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfReconciliationOfEffectiveTaxRateTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_PISAndCofinsMember",
      "name": "ifrs-full:AverageEffectiveTaxRate",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R135": {
     "role": "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative",
     "longName": "999140 - Disclosure - Financial Asset (Indemnity) (Details Narrative)",
     "shortName": "Financial Asset (Indemnity) (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "135",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31_custom_ConcessionAgreementMember",
      "name": "sbs:AdjustmentOfFinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-9",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_ConcessionAgreementMember",
      "name": "sbs:AdjustmentOfFinancialAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-9",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
       "sbs:DisclosureOfFinancialAssetIndemnityExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R136": {
     "role": "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
     "longName": "999141 - Disclosure - Property, plant, and equipment (Details)",
     "shortName": "Property, plant, and equipment (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "136",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PropertyPlantAndEquipment1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfPropertyPlantAndEquipmentTableTextBlock",
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:PropertyPlantAndEquipment1",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfPropertyPlantAndEquipmentTableTextBlock",
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R137": {
     "role": "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1",
     "longName": "999142 - Disclosure - Property, plant, and equipment (Details 1)",
     "shortName": "Property, plant, and equipment (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "137",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:PropertyPlantAndEquipment",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:AdditionsOtherThanThroughBusinessCombinationsPropertyPlantAndEquipment",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfChangesInPropertyPlantAndEquipmentTableTextBlock",
       "sbs:DisclosureOfPropertyPlantAndEquipmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R138": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
     "longName": "999143 - Disclosure - Borrowings and financing (Details)",
     "shortName": "Borrowings and financing (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "138",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:CurrentPortionOfLongtermBorrowings",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:Borrowing",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsAndFinancingOutstandingTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R139": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
     "longName": "999144 - Disclosure - Borrowings and financing (Details 1)",
     "shortName": "Borrowings and financing (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "139",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsPaymentYearOne",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsPaymentScheduleTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsPaymentYearOne",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsPaymentScheduleTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R140": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
     "longName": "999145 - Disclosure - Borrowings and financing (Details 2)",
     "shortName": "Borrowings and financing (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "140",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:Borrowings",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCapitalManagementTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:CashOutflowForLeases",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfChangesInBorrowingsTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R141": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
     "longName": "999146 - Disclosure - Borrowings and financing (Details 3)",
     "shortName": "Borrowings and financing (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "141",
     "firstAnchor": {
      "contextRef": "From2025-02-042025-02-05_custom_ThirtyThreeIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-02-042025-02-05_custom_ThirtyThreeIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R142": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
     "longName": "999147 - Disclosure - Borrowings and financing (Details 4)",
     "shortName": "Borrowings and financing (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "142",
     "firstAnchor": {
      "contextRef": "From2025-06-012025-06-30_custom_IFC2025Member",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-06-012025-06-30_custom_IFC2025Member",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R143": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
     "longName": "999148 - Disclosure - Borrowings and financing (Details 5)",
     "shortName": "Borrowings and financing (Details 5)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "143",
     "firstAnchor": {
      "contextRef": "From2025-07-012025-09-30_custom_ThirtyFourThirtyFiveAndThirtySixIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-07-012025-09-30_custom_ThirtyFourThirtyFiveAndThirtySixIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R144": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
     "longName": "999149 - Disclosure - Borrowings and financing (Details 6)",
     "shortName": "Borrowings and financing (Details 6)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "144",
     "firstAnchor": {
      "contextRef": "From2025-10-012025-12-31_custom_ThirtySevenIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-10-012025-12-31_custom_ThirtySevenIssueDebenturesMember",
      "name": "sbs:FundsRaisedFromUnsecuredDebentures",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R145": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
     "longName": "999150 - Disclosure - Borrowings and financing (Details 7)",
     "shortName": "Borrowings and financing (Details 7)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "145",
     "firstAnchor": {
      "contextRef": "From2025-10-012025-10-31_custom_JICAMember",
      "name": "sbs:AmountCurrencyOfOrigin",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-10-012025-10-31_custom_JICAMember",
      "name": "sbs:AmountCurrencyOfOrigin",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDebenturesTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R146": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8",
     "longName": "999151 - Disclosure - Borrowings and financing (Details 8)",
     "shortName": "Borrowings and financing (Details 8)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "146",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AdjustedEBITDAAdjustedFinancialExpensesMember",
      "name": "sbs:RestrictiveRatios",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfRestrictiveCovenantsRatiosTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_AdjustedEBITDAAdjustedFinancialExpensesMember",
      "name": "sbs:RestrictiveRatios",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfRestrictiveCovenantsRatiosTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R147": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9",
     "longName": "999152 - Disclosure - Borrowings and financing (Details 9)",
     "shortName": "Borrowings and financing (Details 9)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "147",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsAndFinancingCreditLimited",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "p",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsAndFinancingCreditLimitedTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:BorrowingsAndFinancingCreditLimited",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "p",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsAndFinancingCreditLimitedTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R148": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
     "longName": "999153 - Disclosure - Borrowings and financing (Details 10)",
     "shortName": "Borrowings and financing (Details 10)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "148",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_InterAmericanDevelopmentBankMember_custom_FinancialInstitutionMember",
      "name": "sbs:BorrowingsGuarantees",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsTermsTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_InterAmericanDevelopmentBankMember_custom_FinancialInstitutionMember",
      "name": "sbs:BorrowingsGuarantees",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBorrowingsTermsTableTextBlock",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R149": {
     "role": "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
     "longName": "999154 - Disclosure - Borrowings and financing (Details Narrative)",
     "shortName": "Borrowings and financing (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "149",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:LeveragePercentage",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:LeveragePercentage",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfBorrowingsAndFinancingExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R150": {
     "role": "http://sabesp.com.br/role/FinancialInstrumentsDetails",
     "longName": "999155 - Disclosure - Financial instruments (Details)",
     "shortName": "Financial instruments (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "150",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Borrowings",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCapitalManagementTableTextBlock",
       "sbs:DisclosureOfRiskManagementExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_BorrowingsAndFinancingMember",
      "name": "ifrs-full:Borrowings",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ifrs-full:DisclosureOfReclassificationOfFinancialInstrumentsExplanatory",
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R151": {
     "role": "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
     "longName": "999156 - Disclosure - Financial instruments (Details Narrative)",
     "shortName": "Financial instruments (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "151",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:AmountsReceivableRelatedPartyTransactions",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_SABESPMember",
      "name": "ifrs-full:AmountsReceivableRelatedPartyTransactions",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "span",
       "p",
       "ifrs-full:DisclosureOfFinancialInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R152": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
     "longName": "999157 - Disclosure - Derivative financial instruments and hedging transactions (Details)",
     "shortName": "Derivative financial instruments and hedging transactions (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "152",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:GainLossOnFairValueOnHedged",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R153": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
     "longName": "999158 - Disclosure - Derivative financial instruments and hedging transactions (Details 1)",
     "shortName": "Derivative financial instruments and hedging transactions (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "153",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_CashFlowHedgeMember",
      "name": "sbs:GainLossOnDerivativesSwap",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCashFlowHedgeStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R154": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
     "longName": "999159 - Disclosure - Derivative financial instruments and hedging transactions (Details 2)",
     "shortName": "Derivative financial instruments and hedging transactions (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "154",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_DerivativesNotDesignatedMember",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfEffectOfDerivativesNotDesignatedHedgeAccountingTableTextBlock",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R155": {
     "role": "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
     "longName": "999160 - Disclosure - Derivative financial instruments and hedging transactions (Details Narrative)",
     "shortName": "Derivative financial instruments and hedging transactions (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "155",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:DerivativeFinancialLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_DerivativeTransactionsMember",
      "name": "ifrs-full:DerivativeFinancialLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R156": {
     "role": "http://sabesp.com.br/role/TaxesAndContributionsDetails",
     "longName": "999161 - Disclosure - Taxes and contributions (Details)",
     "shortName": "Taxes and contributions (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "156",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:CurrentTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_IncomeTaxAndSocialsContributionMember",
      "name": "ifrs-full:CurrentTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfCurrentTaxAssetsTableTextBlock",
       "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R157": {
     "role": "http://sabesp.com.br/role/TaxesAndContributionsDetails1",
     "longName": "999162 - Disclosure - Taxes and contributions (Details 1)",
     "shortName": "Taxes and contributions (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "157",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:CurrentTaxLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_IncomeTaxAndSocialsContributionMember",
      "name": "ifrs-full:CurrentTaxLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfCurrentTaxLiabilitiesTableTextBlock",
       "ifrs-full:DisclosureOfTaxReceivablesAndPayablesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R158": {
     "role": "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
     "longName": "999163 - Disclosure - Deferred PIS/Cofins taxes (Details)",
     "shortName": "Deferred PIS/Cofins taxes (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "158",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:NetDeferredTaxLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfDeferredPISAndCofinsExplanatory",
       "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:NetDeferredTaxLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfDeferredPISAndCofinsExplanatory",
       "sbs:DisclosureOfDeferredPISAndCofinsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R159": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
     "longName": "999164 - Disclosure - Deferred taxes and contributions (Details)",
     "shortName": "Deferred taxes and contributions (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "159",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:DeferredTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_TaxProvisionMember",
      "name": "ifrs-full:DeferredTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R160": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
     "longName": "999165 - Disclosure - Deferred taxes and contributions (Details 1)",
     "shortName": "Deferred taxes and contributions (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "160",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:DeferredTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_RealizedWithin12MonthsMember",
      "name": "ifrs-full:DeferredTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfRealizationOfDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R161": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
     "longName": "999166 - Disclosure - Deferred taxes and contributions (Details 2)",
     "shortName": "Deferred taxes and contributions (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "161",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:DeferredTaxAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:DeferredTaxAssetChanges",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfChangesInDeferredTaxesTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R162": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3",
     "longName": "999167 - Disclosure - Deferred taxes and contributions (Details 3)",
     "shortName": "Deferred taxes and contributions (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "162",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:ProfitLossBeforeTax",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:ApplicableTaxRates",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfReconciliationOfEffectiveTaxRateTableTextBlock",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R163": {
     "role": "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetailsNarrative",
     "longName": "999168 - Disclosure - Deferred taxes and contributions (Details Narrative)",
     "shortName": "Deferred taxes and contributions (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "163",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:TaxableIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:TaxableIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory",
       "ifrs-full:DisclosureOfDeferredTaxesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R164": {
     "role": "http://sabesp.com.br/role/ProvisionsDetails",
     "longName": "999169 - Disclosure - Provisions (Details)",
     "shortName": "Provisions (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "164",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:ProvisionsGross",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:ProvisionsGross",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R165": {
     "role": "http://sabesp.com.br/role/ProvisionsDetails1",
     "longName": "999170 - Disclosure - Provisions (Details 1)",
     "shortName": "Provisions (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "165",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:Provision",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfChangesInProvisionsTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:Provision",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfChangesInProvisionsTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R166": {
     "role": "http://sabesp.com.br/role/ProvisionsDetails2",
     "longName": "999171 - Disclosure - Provisions (Details 2)",
     "shortName": "Provisions (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "166",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:EstimatedFinancialEffectOfContingentLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfLawsuitsDeemedAsContingentLiabilitiesTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:EstimatedFinancialEffectOfContingentLiabilities",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfLawsuitsDeemedAsContingentLiabilitiesTableTextBlock",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R167": {
     "role": "http://sabesp.com.br/role/ProvisionsDetailsNarrative",
     "longName": "999172 - Disclosure - Provisions (Details Narrative)",
     "shortName": "Provisions (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "167",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:GuaranteeInsuranceForEscrowDepositRenewed",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-6",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:GuaranteeInsuranceForEscrowDepositRenewed",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-6",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfProvisionExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R168": {
     "role": "http://sabesp.com.br/role/LaborAndSocialObligationsDetails",
     "longName": "999173 - Disclosure - Labor and social obligations (Details)",
     "shortName": "Labor and social obligations (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "168",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SalariesAndPayrollCharges",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfEmployeesBenefitsTableTextBlock",
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SalariesAndPayrollCharges",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfEmployeesBenefitsTableTextBlock",
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R169": {
     "role": "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
     "longName": "999174 - Disclosure - Labor and social obligations (Details Narrative)",
     "shortName": "Labor and social obligations (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "169",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:GeneralExpenses",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:GeneralExpenses",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfEmployeeBenefitExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R170": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails",
     "longName": "999175 - Disclosure - Pension plan obligations (Details)",
     "shortName": "Pension plan obligations (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "170",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:DefinedBenefitObligationAtPresentValues",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfPensionPlanBenefitsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:FairValueOfPlansAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfPensionPlanBenefitsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R171": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
     "longName": "999176 - Disclosure - Pension plan obligations (Details 1)",
     "shortName": "Pension plan obligations (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "171",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "sbs:DefinedBenefitObligationAtPresentValues",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfPensionPlanBenefitsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:InterestExpenseIncomeNetDefinedBenefitLiabilityAsset",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfReconciliationOfDefinedBenefitObligationsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R172": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
     "longName": "999177 - Disclosure - Pension plan obligations (Details 2)",
     "shortName": "Pension plan obligations (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "172",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:GainsLossesArisingFromSettlementsNetDefinedBenefitLiabilityAsset",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfGainsLossesDueToChangesInAssumptionsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:GainsLossesArisingFromSettlementsNetDefinedBenefitLiabilityAsset",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfGainsLossesDueToChangesInAssumptionsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R173": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
     "longName": "999178 - Disclosure - Pension plan obligations (Details 3)",
     "shortName": "Pension plan obligations (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "173",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:CurrentServiceCostEmployeeBenefits",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfAmountsRecognizedInIncomeStatementTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:CurrentServiceCostEmployeeBenefits",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfAmountsRecognizedInIncomeStatementTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R174": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
     "longName": "999179 - Disclosure - Pension plan obligations (Details 4)",
     "shortName": "Pension plan obligations (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "174",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_G1PlanMember",
      "name": "sbs:OtherShorttermEmployeeBenefitsOneYear",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfObligationsMaturityTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_G1PlanMember",
      "name": "sbs:OtherShorttermEmployeeBenefitsOneYear",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfObligationsMaturityTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R175": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
     "longName": "999180 - Disclosure - Pension plan obligations (Details 5)",
     "shortName": "Pension plan obligations (Details 5)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "175",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31_custom_G1PlanMember",
      "name": "ifrs-full:ActuarialAssumptionOfDiscountRates",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfActuarialAssumptionsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31_custom_G1PlanMember",
      "name": "ifrs-full:ActuarialAssumptionOfDiscountRates",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfActuarialAssumptionsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R176": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
     "longName": "999181 - Disclosure - Pension plan obligations (Details 6)",
     "shortName": "Pension plan obligations (Details 6)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "176",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_DiscountRateMember_custom_IncreaseOfOnePercentMember_custom_G1PlanMember",
      "name": "sbs:ImpactOnPresentValueOfDefinedBenefitObligations",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfSensitivityAnalysisOfBenefitPlansTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_DiscountRateMember_custom_IncreaseOfOnePercentMember_custom_G1PlanMember",
      "name": "sbs:ImpactOnPresentValueOfDefinedBenefitObligations",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfSensitivityAnalysisOfBenefitPlansTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R177": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
     "longName": "999182 - Disclosure - Pension plan obligations (Details 7)",
     "shortName": "Pension plan obligations (Details 7)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "177",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_G1PlanMember",
      "name": "sbs:EstimateOfContributionExpectedToBePaidToPlan",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBenefitPlanExpensesRecognizedByEmployerTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_G1PlanMember",
      "name": "sbs:EstimateOfContributionExpectedToBePaidToPlan",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfBenefitPlanExpensesRecognizedByEmployerTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R178": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails8",
     "longName": "999183 - Disclosure - Pension plan obligations (Details 8)",
     "shortName": "Pension plan obligations (Details 8)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "178",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:InvestmentFundsAmountContributedToFairValueOfPlanAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfPlanAssetsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:InvestmentFundsAmountContributedToFairValueOfPlanAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfPlanAssetsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R179": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
     "longName": "999184 - Disclosure - Pension plan obligations (Details 10)",
     "shortName": "Pension plan obligations (Details 10)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "179",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:PensionPlanObligationSubtotal",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfReconciliationOfExpensesWithPensionObligationsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:PensionPlanObligationSubtotal",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfReconciliationOfExpensesWithPensionObligationsTableTextBlock",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R180": {
     "role": "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative",
     "longName": "999185 - Disclosure - Pension plan obligations (Details Narrative)",
     "shortName": "Pension plan obligations (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "180",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_SabesprevMaisMember",
      "name": "sbs:NumberOfParticipantsOfDefinedContributionPlan",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_SabesprevMaisMember",
      "name": "sbs:NumberOfParticipantsOfDefinedContributionPlan",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfPensionPlanLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R181": {
     "role": "http://sabesp.com.br/role/ServicesPayableDetails",
     "longName": "999186 - Disclosure - Services payable (Details)",
     "shortName": "Services payable (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "181",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Accruals",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfServicesPayableTableTextBlock",
       "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:Accruals",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfServicesPayableTableTextBlock",
       "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R182": {
     "role": "http://sabesp.com.br/role/ServicesPayableDetailsNarrative",
     "longName": "999187 - Disclosure - Services payable (Details Narrative)",
     "shortName": "Services payable (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "182",
     "firstAnchor": {
      "contextRef": "From2025-07-012025-09-30",
      "name": "ifrs-full:AccountingProfit",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfOtherLiabilitiesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": null
    },
    "R183": {
     "role": "http://sabesp.com.br/role/EquityDetails",
     "longName": "999188 - Disclosure - Equity (Details)",
     "shortName": "Equity (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "183",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:NumberOfSharesIssuedCommon",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfShareCapitalTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:NumberOfSharesIssuedCommon",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfShareCapitalTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R184": {
     "role": "http://sabesp.com.br/role/EquityDetails1",
     "longName": "999189 - Disclosure - Equity  (Details 1)",
     "shortName": "Equity  (Details 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "184",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:ProfitLoss",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "ifrs-full:StatutoryReserve",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfShareholderReturnsTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R185": {
     "role": "http://sabesp.com.br/role/EquityDetails2",
     "longName": "999190 - Disclosure - Equity  (Details 2)",
     "shortName": "Equity  (Details 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "185",
     "firstAnchor": {
      "contextRef": "AsOf2024-12-31",
      "name": "ifrs-full:AccumulatedOtherComprehensiveIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfEquityValuationAdjustmentsTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2023-12-31",
      "name": "ifrs-full:AccumulatedOtherComprehensiveIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfEquityValuationAdjustmentsTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R186": {
     "role": "http://sabesp.com.br/role/EquityDetails3",
     "longName": "999191 - Disclosure - Equity  (Details 3)",
     "shortName": "Equity  (Details 3)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "186",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:NumberOfSharesGranted",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfChangesInNumberOfSharesTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:NumberOfSharesGranted",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfChangesInNumberOfSharesTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R187": {
     "role": "http://sabesp.com.br/role/EquityDetails4",
     "longName": "999192 - Disclosure - Equity  (Details 4)",
     "shortName": "Equity  (Details 4)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "187",
     "firstAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_PerformanceShareMember",
      "name": "ifrs-full:DateOfGrantOfSharebasedPaymentArrangement",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfShareBasedPaymentPlansFairValueTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-012025-12-31_custom_PerformanceShareMember",
      "name": "ifrs-full:DateOfGrantOfSharebasedPaymentArrangement",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "span",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfShareBasedPaymentPlansFairValueTableTextBlock",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R188": {
     "role": "http://sabesp.com.br/role/EquityDetailsNarrative",
     "longName": "999193 - Disclosure - Equity (Details Narrative)",
     "shortName": "Equity (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "188",
     "firstAnchor": {
      "contextRef": "From2025-12-172025-12-18",
      "name": "sbs:AuthorizedCapital",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-12-172025-12-18",
      "name": "sbs:AuthorizedCapital",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfIssuedCapitalsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R189": {
     "role": "http://sabesp.com.br/role/EarningsPerShareDetails",
     "longName": "999194 - Disclosure - Earnings per share (Details)",
     "shortName": "Earnings per share (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "189",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:ProfitLoss",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:WeightedAverageShares",
      "unitRef": "Shares",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:SummaryOfEarningsPerShareBasicAndDilutedTableTextBlock",
       "ifrs-full:DisclosureOfEarningsPerShareExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R190": {
     "role": "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
     "longName": "999195 - Disclosure - Operating segment information (Details)",
     "shortName": "Operating segment information (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "190",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:RevenueAndOperatingIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfOperatingSegmentInformationTableTextBlock",
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:RevenueAndOperatingIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfOperatingSegmentInformationTableTextBlock",
       "sbs:DisclosureOfOperatingSegmentExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R191": {
     "role": "http://sabesp.com.br/role/OperatingRevenueDetails",
     "longName": "999196 - Disclosure - Operating revenue (Details)",
     "shortName": "Operating revenue (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "191",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SanitationServicesRevenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock",
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SanitationServicesRevenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock",
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R192": {
     "role": "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative",
     "longName": "999197 - Disclosure - Operating revenue (Details Narrative)",
     "shortName": "Operating revenue (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "192",
     "firstAnchor": {
      "contextRef": "From2025-04-012025-06-30",
      "name": "ifrs-full:PercentageOfEntitysRevenue",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-04-012025-06-30",
      "name": "ifrs-full:PercentageOfEntitysRevenue",
      "unitRef": "Pure",
      "xsiNil": "false",
      "lang": null,
      "decimals": "INF",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfRevenuesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R193": {
     "role": "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
     "longName": "999198 - Disclosure - Operating costs and expenses (Details)",
     "shortName": "Operating costs and expenses (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "193",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:CostOfSales",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:SellingGeneralAndAdministrativeExpenses",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:SchdeuleOfExpensesByNatureTableTextBlock",
       "ifrs-full:DisclosureOfExpensesByNatureExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R194": {
     "role": "http://sabesp.com.br/role/FinancialIncomeNetDetails",
     "longName": "999199 - Disclosure - Financial Income, net (Details)",
     "shortName": "Financial Income, net (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "194",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:FinanceCosts",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialIncomeExpensesTableTextBlock",
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:FinanceIncomes",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialIncomeExpensesTableTextBlock",
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    },
    "R195": {
     "role": "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetails",
     "longName": "999200 - Disclosure - Other operating income (expenses), net (Details)",
     "shortName": "Other operating income (expenses), net (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "195",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:MiscellaneousOtherOperatingIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfOtherOperatingIncomeExpensesTableTextBlock",
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:MiscellaneousOtherOperatingIncome",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfOtherOperatingIncomeExpensesTableTextBlock",
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R196": {
     "role": "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetailsNarrative",
     "longName": "999201 - Disclosure - Other operating income (expenses), net (Details Narrative)",
     "shortName": "Other operating income (expenses), net (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "196",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:WriteoffOfOperatingAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:WriteoffOfOperatingAssets",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "sbs:DisclosureOfOtherOperatingIncomeExpensesExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R197": {
     "role": "http://sabesp.com.br/role/CommitmentsDetails",
     "longName": "999202 - Disclosure - Commitments (Details)",
     "shortName": "Commitments (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "197",
     "firstAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:ContractLiabilitiesExpenses",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCommitmentsTableTextBlock",
       "ifrs-full:DisclosureOfCommitmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AsOf2025-12-31",
      "name": "sbs:ContractLiabilitiesExpenses",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfCommitmentsTableTextBlock",
       "ifrs-full:DisclosureOfCommitmentsExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R198": {
     "role": "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails",
     "longName": "999203 - Disclosure - Supplemental cash flow information (Details)",
     "shortName": "Supplemental cash flow information (Details)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "198",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:TotalAdditionsToPropertyPlantAndEquipmentNote",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfSupplementalCashFlowInformationTableTextBlock",
       "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "sbs:TotalAdditionsToPropertyPlantAndEquipmentNote",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfSupplementalCashFlowInformationTableTextBlock",
       "sbs:DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true,
      "unique": true
     }
    },
    "R199": {
     "role": "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
     "longName": "999204 - Disclosure - Events after the reporting period (Details Narrative)",
     "shortName": "Events after the reporting period (Details Narrative)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "199",
     "firstAnchor": {
      "contextRef": "From2025-01-01to2025-12-31",
      "name": "ifrs-full:FinanceCosts",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "b",
       "span",
       "td",
       "tr",
       "table",
       "sbs:ScheduleOfFinancialIncomeExpensesTableTextBlock",
       "ifrs-full:DisclosureOfFinanceIncomeExpenseExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "From2024-01-012024-12-31",
      "name": "sbs:NetRevenue",
      "unitRef": "BRL",
      "xsiNil": "false",
      "lang": null,
      "decimals": "-3",
      "ancestors": [
       "span",
       "p",
       "ifrs-full:DisclosureOfEventsAfterReportingPeriodExplanatory",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "sbsform20f_2025.htm",
      "unique": true
     }
    }
   },
   "tag": {
    "ifrs-full_AccountingProfit": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AccountingProfit",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/ServicesPayableDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recognized in profit or loss",
        "verboseLabel": "Recrecognized in profit or loss"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of profit (loss) for a period before deducting tax expense. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r42",
      "r43"
     ]
    },
    "sbs_AccountsReceivableAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccountsReceivableAxis",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accounts Receivable [Axis]",
        "verboseLabel": "AccountsReceivableAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AccountsReceivableDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccountsReceivableDomain",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "auth_ref": []
    },
    "sbs_AccountsReceivableFromRelatedPartiesNonCurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccountsReceivableFromRelatedPartiesNonCurrent",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Accounts receivable from related parties",
        "label": "AccountsReceivableFromRelatedPartiesNonCurrent"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Accruals": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Accruals",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayableDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Service providers"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities to pay for goods or services that have been received or supplied but have not been paid, invoiced or formally agreed with the supplier, including amounts due to employees."
       }
      }
     },
     "auth_ref": [
      "r380"
     ]
    },
    "sbs_AccruedExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccruedExpenses",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accrued expenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AccruedInterestOnBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccruedInterestOnBorrowings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accrued interest"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AccumulatedAmortization": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccumulatedAmortization",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Accumulated amortization",
        "label": "AccumulatedAmortization"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AccumulatedAmortizationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccumulatedAmortizationMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated Amortization [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AccumulatedAmortizationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AccumulatedAmortizationsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated Amortizations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AccumulatedOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AccumulatedOtherComprehensiveIncome",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Equity valuation adjustments, beginning",
        "periodEndLabel": "Equity valuation adjustments, ending",
        "label": "Accumulated other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of accumulated items of income and expense (including reclassification adjustments) that are not recognised in profit or loss as required or permitted by other IFRSs. [Refer: IFRSs [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_AcquiredConsiderationPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquiredConsiderationPerShare",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquired consideration"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquiredPricePerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquiredPricePerShare",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquired price per share"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionCapitalInterestRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionCapitalInterestRate",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquisition total capital"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionCommonInterestRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionCommonInterestRate",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquisition common interest rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionPreferredSharePrice": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionPreferredSharePrice",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquired preferred share"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionShareCapitalInterestRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionShareCapitalInterestRate",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquisition share capital interest rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionSharePrice": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionSharePrice",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquired common share"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AcquisitionSharesIssued": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AcquisitionSharesIssued",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquisition shares issued"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActiveParticipantsOfPlan": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActiveParticipantsOfPlan",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Active participants of plan"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ActuarialAssumptionOfDiscountRates": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialAssumptionOfDiscountRates",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Discount rate - actual rate (NTN-B)"
       }
      },
      "en": {
       "role": {
        "documentation": "The discount rate used as the significant actuarial assumption to determine the present value of a defined benefit obligation. [Refer: Defined benefit obligation, at present value; Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r389"
     ]
    },
    "ifrs-full_ActuarialAssumptionOfExpectedRatesOfInflation": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialAssumptionOfExpectedRatesOfInflation",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflation rate"
       }
      },
      "en": {
       "role": {
        "documentation": "The expected rate of inflation that is used as a significant actuarial assumption to determine the present value of a defined benefit obligation. [Refer: Defined benefit plans [domain]; Defined benefit obligation, at present value; Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r389"
     ]
    },
    "ifrs-full_ActuarialAssumptionOfExpectedRatesOfSalaryIncreases": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialAssumptionOfExpectedRatesOfSalaryIncreases",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Nominal rate of salary growth"
       }
      },
      "en": {
       "role": {
        "documentation": "The expected rate of salary increases used as a significant actuarial assumption to determine the present value of a defined benefit obligation. [Refer: Defined benefit plans [domain]; Defined benefit obligation, at present value; Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r389"
     ]
    },
    "sbs_ActuarialAssumptionOfMortalityRates2": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialAssumptionOfMortalityRates2",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Mortality table"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ActuarialAssumptionsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialAssumptionsAxis",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial assumptions [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r61"
     ]
    },
    "ifrs-full_ActuarialAssumptionsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialAssumptionsDomain",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all actuarial assumptions. Actuarial assumptions are the entity\u2019s unbiased and mutually compatible best estimates of the demographic and financial variables that will determine the ultimate cost of providing post-employment benefits. It also represents the standard value for the 'Actuarial assumptions' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r61"
     ]
    },
    "sbs_ActuarialDeficit": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialDeficit",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial deficit"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActuarialDeficitParticipants": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialDeficitParticipants",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial deficit participants"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActuarialGainLossG1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialGainLossG1Member",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial Gain Loss G 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ActuarialGainsLossesArisingFromChangesInFinancialAssumptionsNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ActuarialGainsLossesArisingFromChangesInFinancialAssumptionsNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial gains (losses)"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in a net defined benefit liability (asset) resulting from actuarial gains (losses) arising from changes in financial assumptions that result in remeasurements of the net defined benefit liability (asset). Financial assumptions deal with items such as: (a) the discount rate; (b) benefit levels, excluding any cost of the benefits to be met by employees, and future salary; (c) in the case of medical benefits, future medical costs, including claim handling costs (ie the costs that will be incurred in processing and resolving claims, including legal and adjuster's fees); and (d) taxes payable by the plan on contributions relating to service before the reporting date or on benefits resulting from that service. [Refer: Net defined benefit liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r55"
     ]
    },
    "sbs_ActuarialGainsLossesRecordedAsOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialGainsLossesRecordedAsOtherComprehensiveIncome",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial (gains)/losses recorded as other comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActuarialGainslossesRecordedAsOtherComprehensiveIncome1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialGainslossesRecordedAsOtherComprehensiveIncome1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial gains/(losses) recorded as other comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActuarialLiabilityAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialLiabilityAmount",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial liability amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ActuarialRetainedEarningsAccumulatedLossesOnDefinedBenefitPlansNetOfTaxes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ActuarialRetainedEarningsAccumulatedLossesOnDefinedBenefitPlansNetOfTaxes",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial retained earnings (accumulated losses) on Defined Benefit Plans, net of taxes"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_Additional402vDisclosureTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "Additional402vDisclosureTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional 402(v) Disclosure"
       }
      }
     },
     "auth_ref": [
      "r321"
     ]
    },
    "sbs_AdditionalAllowanceRecognisedInProfitOrLossAllowanceAccountForCreditLossesOfFinancialAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionalAllowanceRecognisedInProfitOrLossAllowanceAccountForCreditLossesOfFinancialAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recognition/(reversal) of allowance"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdditionalProvisionOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionalProvisionOtherProvisions",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional provisions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdditionsOtherConcessionAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionsOtherConcessionAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additions \u2013 Other concession assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdditionsOtherThanThroughBusinessCombinationsIntangibleAssetOtherThanGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionsOtherThanThroughBusinessCombinationsIntangibleAssetOtherThanGoodwill",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Additions",
        "label": "AdditionsOtherThanThroughBusinessCombinationsIntangibleAssetOtherThanGoodwill"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdditionsOtherThanThroughBusinessCombinationsInvestmentProperty": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdditionsOtherThanThroughBusinessCombinationsInvestmentProperty",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of additions to investment property other than those acquired through business combinations. [Refer: Total for all business combinations [member]; Investment property]"
       }
      }
     },
     "auth_ref": [
      "r100",
      "r102"
     ]
    },
    "ifrs-full_AdditionsOtherThanThroughBusinessCombinationsPropertyPlantAndEquipment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdditionsOtherThanThroughBusinessCombinationsPropertyPlantAndEquipment",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Additions",
        "label": "Additions other than through business combinations, property, plant and equipment"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of additions to property, plant and equipment other than those acquired through business combinations. [Refer: Total for all business combinations [member]; Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r48"
     ]
    },
    "sbs_AdditionsRevenueConstruction": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionsRevenueConstruction",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additions - Contract asset related to service concession agreements (Note 30)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdditionsToContractAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionsToContractAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total additions to contract assets (Note 13)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdditionsToIntangibleAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdditionsToIntangibleAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total additions to intangible assets (Note 14 (b))"
       }
      }
     },
     "auth_ref": []
    },
    "dei_AddressTypeDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AddressTypeDomain",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "An entity may have several addresses for different purposes and this domain represents all such types."
       }
      }
     },
     "auth_ref": []
    },
    "ecd_AdjToCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AdjToCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustment to Compensation, Amount"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "ecd_AdjToCompAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AdjToCompAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustment to Compensation [Axis]"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "ecd_AdjToNonPeoNeoCompFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AdjToNonPeoNeoCompFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustment to Non-PEO NEO Compensation Footnote"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "ecd_AdjToPeoCompFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AdjToPeoCompFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustment To PEO Compensation, Footnote"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "sbs_AdjustedEBITDAAdjustedFinancialExpensesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustedEBITDAAdjustedFinancialExpensesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjusted Net Debt / Adjusted EBITDA [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdjustedNetDebtAdjustedEBITDAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustedNetDebtAdjustedEBITDAMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Adjusted Net Debt / Adjusted EBITDA [Member]",
        "label": "Adjusted Net Debt / Adjusted EBITDA [Member] [Default Label]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdjustmentOfFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentOfFinancialAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustment of financial assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdjustmentsForDecreaseIncreaseInDeferredCofinsPASEP": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForDecreaseIncreaseInDeferredCofinsPASEP",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Deferred PIS/Cofins",
        "label": "AdjustmentsForDecreaseIncreaseInDeferredCofinsPASEP"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInInventories": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInInventories",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Inventories",
        "label": "Adjustments for decrease (increase) in inventories"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in inventories to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Inventories; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r397"
     ]
    },
    "sbs_AdjustmentsForDecreaseIncreaseInLaborAndSocialObligations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForDecreaseIncreaseInLaborAndSocialObligations",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Labor and social obligations",
        "label": "AdjustmentsForDecreaseIncreaseInLaborAndSocialObligations"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInOtherAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other assets",
        "label": "Adjustments for decrease (increase) in other assets"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in other assets to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Other assets; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r400"
     ]
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInOtherOperatingReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInOtherOperatingReceivables",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Related-party balances and transactions"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in other operating receivables to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r397"
     ]
    },
    "sbs_AdjustmentsForDecreaseIncreaseInTaxesAndContributionsPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForDecreaseIncreaseInTaxesAndContributionsPayable",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Taxes and contributions payable",
        "label": "AdjustmentsForDecreaseIncreaseInTaxesAndContributionsPayable"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInTradeAccountReceivable",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade receivables",
        "label": "Adjustments for decrease (increase) in trade accounts receivable"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in trade accounts receivable to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r397"
     ]
    },
    "ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDepreciationAndAmortisationExpense",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Depreciation and amortization"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for depreciation and amortisation expense to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Depreciation and amortisation expense; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r398"
     ]
    },
    "ifrs-full_AdjustmentsForDepreciationExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForDepreciationExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amortization expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for depreciation expense to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r400"
     ]
    },
    "ifrs-full_AdjustmentsForFinanceCosts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForFinanceCosts",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest calculated on borrowings and financing payable"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for finance costs to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Finance costs; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r399"
     ]
    },
    "ifrs-full_AdjustmentsForImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/StatementsOfIncome",
      "http://sabesp.com.br/role/TradeReceivablesDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Allowance for doubtful accounts",
        "negatedTerseLabel": "Amount recorded as expense (Note 31)",
        "label": "Adjustments for impairment loss (reversal of impairment loss) recognised in profit or loss"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for impairment loss (reversal of impairment loss) recognised in profit or loss to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Impairment loss (reversal of impairment loss) recognised in profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r398"
     ]
    },
    "ifrs-full_AdjustmentsForIncomeTaxExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForIncomeTaxExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net of withholding income tax"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for income tax expense to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r108"
     ]
    },
    "sbs_AdjustmentsForIncreaseDecreaseInEscrowDeposits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForIncreaseDecreaseInEscrowDeposits",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Escrow Deposits",
        "label": "AdjustmentsForIncreaseDecreaseInEscrowDeposits"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForIncreaseDecreaseInOtherLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 15.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other liabilities",
        "label": "Adjustments for increase (decrease) in other liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for increase (decrease) in other liabilities to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Other liabilities; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r400"
     ]
    },
    "ifrs-full_AdjustmentsForIncreaseDecreaseInOtherOperatingPayables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForIncreaseDecreaseInOtherOperatingPayables",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Services payable",
        "label": "Adjustments for increase (decrease) in other operating payables"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for increase (decrease) in other operating payables to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r397"
     ]
    },
    "ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForIncreaseDecreaseInTradeAccountPayable",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade payables and contractors",
        "label": "Adjustments for increase (decrease) in trade accounts payable"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for increase (decrease) in trade accounts payable to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r397"
     ]
    },
    "ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Residual value of property, plant and equipment, intangible assets and investment properties written-off"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for losses (gains) on disposal of non-current assets to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Non-current assets; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r395"
     ]
    },
    "sbs_AdjustmentsForPensionObligations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForPensionObligations",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": -1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Pension plan obligations",
        "label": "AdjustmentsForPensionObligations"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForProvisions",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions",
        "label": "Adjustments for provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for provisions to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Provisions; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r398"
     ]
    },
    "ifrs-full_AdjustmentsForReconcileProfitLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForReconcileProfitLoss",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total Adjustments",
        "label": "Adjustments to reconcile profit (loss)"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r106"
     ]
    },
    "ifrs-full_AdjustmentsForReconcileProfitLossAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdjustmentsForReconcileProfitLossAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments for reconciliation of net income:"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AdjustmentsForRecoverableTaxes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AdjustmentsForRecoverableTaxes",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperations",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Taxes Recoverable",
        "label": "AdjustmentsForRecoverableTaxes"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdministrativeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AdministrativeExpense",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": -1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Administrative expenses",
        "label": "Administrative expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expenses that the entity classifies as being administrative."
       }
      }
     },
     "auth_ref": [
      "r38",
      "r77",
      "r215"
     ]
    },
    "ifrs-full_AggregateOfFairValuesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AggregateOfFairValuesMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the aggregate of fair values. It also represents the standard value for the 'Fair value as deemed cost' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r121"
     ]
    },
    "ecd_AggtErrCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AggtErrCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aggregate Erroneous Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r288",
      "r299",
      "r313",
      "r339"
     ]
    },
    "ecd_AggtErrCompNotYetDeterminedTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AggtErrCompNotYetDeterminedTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aggregate Erroneous Compensation Not Yet Determined"
       }
      }
     },
     "auth_ref": [
      "r291",
      "r302",
      "r316",
      "r342"
     ]
    },
    "sbs_AgreementForTheInstallmentPaymentOfSanitationServicesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementForTheInstallmentPaymentOfSanitationServicesMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Agreement For The Installment Payment Of Sanitation Services [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsConcessionNewContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsConcessionNewContractsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Agreements Concession New Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsConcessionOthersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsConcessionOthersMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Agreements Concession Others [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsConcessionURAE1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsConcessionURAE1Member",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession agreement \u0096 URAE-1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsEconomicValueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsEconomicValueMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession agreements \u0096 economic value [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsEquityValueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsEquityValueMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession agreements \u0096 equity value [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Agreements [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsNewContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsNewContractsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession agreements \u0096 new contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsOthersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsOthersMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession agreements \u0096 others [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AgreementsURAE1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AgreementsURAE1Member",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Concession agreement \u0096 URAE-1 [Member]",
        "label": "Concession agreement \u2013 URAE-1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AguasDeAndradinaMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AguasDeAndradinaMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aguas De Andradina [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AguasDeAndradinasMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AguasDeAndradinasMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aguas De Andradinas [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AguasDeCastilhoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AguasDeCastilhoMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aguas De Castilho [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_AllAdjToCompMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AllAdjToCompMember",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "auth_ref": [
      "r327"
     ]
    },
    "ecd_AllExecutiveCategoriesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AllExecutiveCategoriesMember",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "auth_ref": [
      "r334"
     ]
    },
    "ecd_AllIndividualsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AllIndividualsMember",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure",
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure",
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements",
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r334",
      "r343",
      "r347",
      "r355"
     ]
    },
    "ecd_AllTradingArrangementsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AllTradingArrangementsMember",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "auth_ref": [
      "r353"
     ]
    },
    "sbs_AllowanceAccountForCreditLossOfFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceAccountForCreditLossOfFinancialAssets",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Allowance for doubtful accounts",
        "label": "AllowanceAccountForCreditLossOfFinancialAssets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceAccountForCreditLossesOfFinancialAssets1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceAccountForCreditLossesOfFinancialAssets1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Balance at the beginning of year",
        "periodEndLabel": "Total",
        "label": "AllowanceAccountForCreditLossesOfFinancialAssets1"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForDoubtfulAccounts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForDoubtfulAccounts",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance for doubtful accounts"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForDoubtfulAccountsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForDoubtfulAccountsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Doubtful Accounts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForInventoryLossesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForInventoryLossesMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Inventory Losses [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForLossMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForLossMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Loss [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForLossesOnOtherAccountsReceivableMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForLossesOnOtherAccountsReceivableMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Losses On Other Accounts Receivable [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForLossesOnWorksAndProjectsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForLossesOnWorksAndProjectsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Losses On Works And Projects [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AllowanceForLossesOnWriteOffOfAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AllowanceForLossesOnWriteOffOfAssetsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Losses On Write Off Of Assets [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AltoTieteMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AltoTieteMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Alto Tiete [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_AmendmentDescription": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AmendmentDescription",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amendment Description",
        "documentation": "Description of changes contained within amended document."
       }
      }
     },
     "auth_ref": []
    },
    "dei_AmendmentFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AmendmentFlag",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amendment Flag",
        "documentation": "Boolean flag that is true when the XBRL content amends previously-filed or accepted submission."
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmendmentsToIFRS9Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmendmentsToIFRS9Member",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amendments To I F R S 9 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AmortisationIntangibleAssetsOtherThanGoodwill",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Amortization",
        "label": "Amortisation, intangible assets other than goodwill"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of amortisation of intangible assets other than goodwill. [Refer: Depreciation and amortisation expense; Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r95"
     ]
    },
    "sbs_AmortizationAverageRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmortizationAverageRate",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Average amortization rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmortizationOfBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmortizationOfBorrowings",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amortization of borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmountCurrencyOfOrigin": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountCurrencyOfOrigin",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amount (Currency of Origin)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmountReceivedFromGESP": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountReceivedFromGESP",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amount received from State of Sao Paulo (undisputed)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipAltoTiete": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipAltoTiete",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Intangible assets",
        "label": "AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipAltoTiete"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipSaoLourenco": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipSaoLourenco",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Intangible assets",
        "label": "AmountRecordedInIntangibleAssetsOfThePublicPrivatePartnershipSaoLourenco"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AmountsReceivableRelatedPartyTransaction": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountsReceivableRelatedPartyTransaction",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total current"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AmountsReceivableRelatedPartyTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AmountsReceivableRelatedPartyTransactions",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accounts receivable from related parties",
        "verboseLabel": "Financial assets receivable from related parties"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts receivable resulting from related party transactions. [Refer: Total for all related parties [member]]"
       }
      }
     },
     "auth_ref": [
      "r70",
      "r73"
     ]
    },
    "sbs_AmountsReclassifiedFromOciToProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AmountsReclassifiedFromOciToProfitOrLoss",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amounts reclassified from OCI to profit or loss"
       }
      }
     },
     "auth_ref": []
    },
    "dei_AnnualInformationForm": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AnnualInformationForm",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Annual Information Form",
        "documentation": "Boolean flag with value true on a form if it is an annual report containing an annual information form."
       }
      }
     },
     "auth_ref": [
      "r295"
     ]
    },
    "sbs_AnnualReveuneCalculatedRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AnnualReveuneCalculatedRate",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Annual revenue calculated rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ApplicableTaxRates": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ApplicableTaxRates",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statutory rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AquapoloAmbientalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AquapoloAmbientalMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aquapolo Ambiental [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AssetCeiling": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AssetCeiling",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Asset ceiling"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Assets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Assets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total Assets",
        "label": "Assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of a present economic resource controlled by the entity as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": [
      "r18",
      "r137",
      "r138",
      "r139",
      "r199",
      "r203"
     ]
    },
    "sbs_AssetsCeiling": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AssetsCeiling",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Asset ceiling",
        "label": "AssetsCeiling"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AssetsHeldForSale": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AssetsHeldForSale",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets held for sale"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AssetsLiabilitiesOfBenefitPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AssetsLiabilitiesOfBenefitPlan",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional retirement and pension plan"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets of a retirement benefit plan less liabilities other than the actuarial present value of promised retirement benefits."
       }
      }
     },
     "auth_ref": [
      "r75"
     ]
    },
    "sbs_AssignmentOfReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AssignmentOfReceivables",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assignment of receivables"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AttendAmbientalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AttendAmbientalMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Attend Ambiental [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_AuditedAnnualFinancialStatements": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AuditedAnnualFinancialStatements",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Audited Annual Financial Statements",
        "documentation": "Boolean flag with value true on a form if it is an annual report containing audited financial statements."
       }
      }
     },
     "auth_ref": [
      "r295"
     ]
    },
    "dei_AuditorFirmId": {
     "xbrltype": "nonemptySequenceNumberItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AuditorFirmId",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Auditor Firm ID",
        "documentation": "PCAOB issued Audit Firm Identifier"
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295"
     ]
    },
    "dei_AuditorLocation": {
     "xbrltype": "internationalNameItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AuditorLocation",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Auditor Location"
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295"
     ]
    },
    "dei_AuditorName": {
     "xbrltype": "internationalNameItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "AuditorName",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Auditor Name"
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295"
     ]
    },
    "sbs_AuthorizationToIncreaseCapital": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AuthorizationToIncreaseCapital",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Authorization to increase capital"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AuthorizedCapital": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AuthorizedCapital",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AverageEffectiveTaxRate": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "AverageEffectiveTaxRate",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxable income rates",
        "verboseLabel": "Effective rate"
       }
      },
      "en": {
       "role": {
        "documentation": "The tax expense (income) divided by the accounting profit. [Refer: Accounting profit]"
       }
      }
     },
     "auth_ref": [
      "r43"
     ]
    },
    "sbs_AverageYieldOfCashEquivalents": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AverageYieldOfCashEquivalents",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Average yield of cash equivalents"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_AverageYieldOfFinancialInstrument": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "AverageYieldOfFinancialInstrument",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Average yield, percentage"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_AwardExrcPrice": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardExrcPrice",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exercise Price"
       }
      }
     },
     "auth_ref": [
      "r350"
     ]
    },
    "ecd_AwardGrantDateFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardGrantDateFairValue",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value as of Grant Date"
       }
      }
     },
     "auth_ref": [
      "r351"
     ]
    },
    "ecd_AwardTmgDiscLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgDiscLineItems",
     "auth_ref": [
      "r346"
     ]
    },
    "ecd_AwardTmgHowMnpiCnsdrdTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgHowMnpiCnsdrdTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Timing, How MNPI Considered"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "ecd_AwardTmgMethodTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgMethodTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Timing Method"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "ecd_AwardTmgMnpiCnsdrdFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgMnpiCnsdrdFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Timing MNPI Considered"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "ecd_AwardTmgMnpiDiscTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgMnpiDiscTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Timing MNPI Disclosure"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "ecd_AwardTmgPredtrmndFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardTmgPredtrmndFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Timing Predetermined"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "us-gaap_AwardTypeAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://fasb.org/us-gaap/2024",
     "localname": "AwardTypeAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Award Type [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_AwardUndrlygSecuritiesAmt": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardUndrlygSecuritiesAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Underlying Securities"
       }
      }
     },
     "auth_ref": [
      "r349"
     ]
    },
    "ecd_AwardsCloseToMnpiDiscIndName": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardsCloseToMnpiDiscIndName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Name",
        "label": "Awards Close in Time to MNPI Disclosures, Individual Name"
       }
      }
     },
     "auth_ref": [
      "r348"
     ]
    },
    "ecd_AwardsCloseToMnpiDiscTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardsCloseToMnpiDiscTable",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Awards Close in Time to MNPI Disclosures [Table]"
       }
      }
     },
     "auth_ref": [
      "r347"
     ]
    },
    "ecd_AwardsCloseToMnpiDiscTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "AwardsCloseToMnpiDiscTableTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Awards Close in Time to MNPI Disclosures, Table"
       }
      }
     },
     "auth_ref": [
      "r347"
     ]
    },
    "sbs_BID1212Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BID1212Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "B I D 1212 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BNDESMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BNDESMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "B N D E S [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BTGPactualBankMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BTGPactualBankMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "BTG Pactual Bank [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoBTGPactualSAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoBTGPactualSAMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco B T G Pactual S A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoBVMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoBVMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco B V [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoBradescoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoBradescoMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco Bradesco [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoCitibankMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoCitibankMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco Citibank [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoDoBrasilSAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoDoBrasilSAMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco Do Brasil S A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoItauMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoItauMember",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco Itau [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BancoSantanderSAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BancoSantanderSAMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Banco Santander S A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BarueriEnergiaRenovavelMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BarueriEnergiaRenovavelMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Barueri Energia Renovavel [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BasicEarningsLossPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BasicEarningsLossPerShare",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings per share - basic (in reais)",
        "verboseLabel": "Basic earnings per share (reais per share)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of profit (loss) attributable to ordinary equity holders of the parent entity (the numerator) divided by the weighted average number of ordinary shares outstanding during the period (the denominator)."
       }
      }
     },
     "auth_ref": [
      "r83",
      "r84"
     ]
    },
    "sbs_BlueBondMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BlueBondMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Blue Bond [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BlueBondsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BlueBondsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Blue Bonds [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BlueSeniorUnsecuredNotesBlueBondsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BlueSeniorUnsecuredNotesBlueBondsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Blue Senior Unsecured Notes Blue Bonds [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BondsIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BondsIssued",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Securities issued"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of bonds issued by the entity."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_Borrowing": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Borrowing",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "Borrowing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingAndFinancing": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingAndFinancing",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Borrowings and financing",
        "label": "BorrowingAndFinancing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingAndFinancings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingAndFinancings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Borrowings and financing",
        "label": "BorrowingAndFinancings"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BorrowingCostsIncurred": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingCostsIncurred",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Borrowing cost",
        "label": "Borrowing costs incurred"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest and other costs that an entity incurs in connection with the borrowing of funds."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_BorrowingCostsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingCostsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowing Costs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BorrowingCostsRecognisedAsExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingCostsRecognisedAsExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expenses with borrowing costs"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest and other costs that an entity incurs in connection with the borrowing of funds that are recognised as an expense."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_BorrowingFunding": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingFunding",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Funding",
        "label": "BorrowingFunding"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingFundingCosts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingFundingCosts",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowing costs"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Borrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Borrowings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails",
      "http://sabesp.com.br/role/RiskManagementDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total borrowings and financing (Note 17)",
        "periodStartLabel": "Borrowings and financing, beginning",
        "periodEndLabel": "Borrowings and financing, ending",
        "verboseLabel": "Carrying amount"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of outstanding funds that the entity is obligated to repay."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_BorrowingsAndFinancing": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsAndFinancing",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsAndFinancingAmounts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsAndFinancingAmounts",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Borrowings and financing",
        "label": "BorrowingsAndFinancingAmounts"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsAndFinancingCreditLimited": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsAndFinancingCreditLimited",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings and financing - credit limits"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsAndFinancingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsAndFinancingMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings And Financing [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BorrowingsByNameAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingsByNameAxis",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings by name [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "ifrs-full_BorrowingsByNameDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingsByNameDomain",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all borrowings when disaggregated by name. It also represents the standard value for the 'Borrowings by name' axis if no other member is used. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "sbs_BorrowingsGuarantees": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsGuarantees",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Guarantees"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsInterestAndChargesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsInterestAndChargesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings Interest And Charges [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BorrowingsInterestRate": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingsInterestRate",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest rate"
       }
      },
      "en": {
       "role": {
        "documentation": "The interest rate on borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "ifrs-full_BorrowingsInterestRateBasis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingsInterestRateBasis",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Rate",
        "verboseLabel": "Annual interest rate",
        "terseLabel": "Interest rate, description"
       }
      },
      "en": {
       "role": {
        "documentation": "The basis (reference rate) used for calculation of the interest rate on borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "ifrs-full_BorrowingsMaturity": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BorrowingsMaturity",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maturity",
        "verboseLabel": "Final maturity"
       }
      },
      "en": {
       "role": {
        "documentation": "The maturity of borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "sbs_BorrowingsPaymentNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentNet",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings payment net"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentThereafter": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentThereafter",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2031 to 2048"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearFive": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearFive",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2030"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearFour": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearFour",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2029"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearOne": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearOne",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2026"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearSix": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearSix",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2031"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearThree": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearThree",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2028"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsPaymentYearTwo": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsPaymentYearTwo",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "2027"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BorrowingsProvisionForInterestRatesAndFeesCapitalized": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BorrowingsProvisionForInterestRatesAndFeesCapitalized",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision for interest and charges -capitalized"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BrazilianDevelopmentBankMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BrazilianDevelopmentBankMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brazilian Development Bank [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BrazilianDevelopmentsBankBNDESMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BrazilianDevelopmentsBankBNDESMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brazilian Development Bank \u0096 BNDES [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BrazilianFederalSavingsBankMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BrazilianFederalSavingsBankMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brazilian Federal Savings Bank [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_BrazilianFederalSavingsBanksMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "BrazilianFederalSavingsBanksMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brazilian Federal Savings Banks [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BuildingsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "BuildingsMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Buildings [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of plant, property and equipment representing depreciable buildings and similar structures for use in operations. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r385"
     ]
    },
    "dei_BusinessContactMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "BusinessContactMember",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Business Contact [Member]",
        "documentation": "Business contact for the entity"
       }
      }
     },
     "auth_ref": [
      "r272",
      "r295"
     ]
    },
    "sbs_CDIMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CDIMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "C D I [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CDINetExposureMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CDINetExposureMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "C D I Net Exposure [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CDISeriesThreeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CDISeriesThreeMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "C D I Series Three [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_COFINSAndPasepMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "COFINSAndPasepMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "C O F I N S And Pasep [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CantareiraSPEnergiaMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CantareiraSPEnergiaMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cantareira S P Energia [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CapitalIncrease": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalIncrease",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital increase",
        "verboseLabel": "Capital increase"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CapitalIncreaseAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalIncreaseAmount",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Capital increase",
        "label": "CapitalIncreaseAmount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CapitalIsncrease": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalIsncrease",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital increase"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CapitalPercentageOfShares": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalPercentageOfShares",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of shares, capital"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CapitalReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CapitalReserve",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital reserves"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing the capital reserves."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_CapitalReserveMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CapitalReserveMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital reserve [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing capital reserves."
       }
      }
     },
     "auth_ref": [
      "r376"
     ]
    },
    "sbs_CapitalizationBorrowingCostsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalizationBorrowingCostsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capitalization Borrowing Costs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CapitalizationOfInvestmentReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CapitalizationOfInvestmentReserve",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capitalization of investment reserve"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Cash": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Cash",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash and banks"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash on hand and demand deposits. [Refer: Cash on hand]"
       }
      }
     },
     "auth_ref": [
      "r401"
     ]
    },
    "ifrs-full_CashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashAndCashEquivalents",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetails",
      "http://sabesp.com.br/role/StatementsOfCashFlows",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash and cash equivalents",
        "periodStartLabel": "Cash and cash equivalents at the beginning of the year",
        "periodEndLabel": "Cash and cash equivalents at the end of the year",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash on hand and demand deposits, along with short-term, highly liquid investments that are readily convertible to known amounts of cash and that are subject to an insignificant risk of changes in value. [Refer: Cash; Cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r13",
      "r111",
      "r133"
     ]
    },
    "sbs_CashAndCashEquivalents1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CashAndCashEquivalents1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "(-) Cash and cash equivalents (Note 7)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CashAndCashEquivalentsRepresentedByAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CashAndCashEquivalentsRepresentedByAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Represented by:"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash equivalents"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of short-term, highly liquid investments that are readily convertible to known amounts of cash and that are subject to an insignificant risk of changes in value."
       }
      }
     },
     "auth_ref": [
      "r401"
     ]
    },
    "sbs_CashFlowHedgeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CashFlowHedgeMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flow Hedge [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInDecreaseIncreaseInRestrictedCashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInDecreaseIncreaseInRestrictedCashAndCashEquivalents",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Restricted cash",
        "label": "Cash flows from (used in) decrease (increase) in restricted cash and cash equivalents"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash inflow (outflow) due to a decrease (increase) in restricted cash and cash equivalents. [Refer: Restricted cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r396"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInFinancingActivities",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalents",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Net cash generated from (used in) financing activities",
        "label": "Cash flows from (used in) financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) financing activities, which are activities that result in changes in the size and composition of the contributed equity and borrowings of the entity, from continuing and discontinued operations."
       }
      }
     },
     "auth_ref": [
      "r104",
      "r112"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInFinancingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInFinancingActivitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Cash flows from financing activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInInvestingActivities",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalents",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Net cash used in investment activities",
        "label": "Cash flows from (used in) investing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) investing activities, which are the acquisition and disposal of long-term assets and other investments not included in cash equivalents, from continuing and discontinued operations."
       }
      }
     },
     "auth_ref": [
      "r104",
      "r112"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInInvestingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInInvestingActivitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash flows from financing activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInOperatingActivities",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalents",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Net cash generated from operating activities",
        "label": "Cash flows from (used in) operating activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) operating activities, which are the principal revenue-producing activities of the entity and other activities that are not investing or financing activities, from continuing and discontinued operations. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r104",
      "r112"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInOperatingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInOperatingActivitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash flows from operating activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInOperations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashFlowsFromUsedInOperations",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Cash generated from operations",
        "label": "Cash flows from (used in) operations"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash from (used in) the entity's operations."
       }
      }
     },
     "auth_ref": [
      "r236",
      "r238"
     ]
    },
    "sbs_CashInflowOutflowRightofuseAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CashInflowOutflowRightofuseAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Right of use",
        "label": "CashInflowOutflowRightofuseAssets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashOutflowForLeases": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CashOutflowForLeases",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Additions",
        "label": "Cash outflow for leases"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for leases."
       }
      }
     },
     "auth_ref": [
      "r150"
     ]
    },
    "ifrs-full_CategoriesOfRelatedPartiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CategoriesOfRelatedPartiesAxis",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/IntangibleAssetsDetails4",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Categories of related parties [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r72"
     ]
    },
    "ifrs-full_CategoriesOfRelatedPartiesDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CategoriesOfRelatedPartiesDomain",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/IntangibleAssetsDetails4",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Categories of related parties' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r72"
     ]
    },
    "sbs_CertificadoDeDepositoInterbancarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CertificadoDeDepositoInterbancarioMember",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Certificado De Deposito Interbancario [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_ChangedPeerGroupFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ChangedPeerGroupFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changed Peer Group, Footnote"
       }
      }
     },
     "auth_ref": [
      "r325"
     ]
    },
    "dei_CityAreaCode": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "CityAreaCode",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "City Area Code",
        "documentation": "Area code of city"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ClassesOfAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfAssetsAxis",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of assets [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r88",
      "r89",
      "r140",
      "r152"
     ]
    },
    "ifrs-full_ClassesOfAssetsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfAssetsDomain",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for a present economic resource controlled by the entity as a result of past events. Economic resource is a right that has the potential to produce economic benefits. It also represents the standard value for the 'Classes of assets' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r88",
      "r140",
      "r152"
     ]
    },
    "ifrs-full_ClassesOfEntitysOwnEquityInstrumentsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfEntitysOwnEquityInstrumentsAxis",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of entity's own equity instruments [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r140"
     ]
    },
    "ifrs-full_ClassesOfEntitysOwnEquityInstrumentsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfEntitysOwnEquityInstrumentsDomain",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for equity instruments issued by the entity. It also represents the standard value for the 'Classes of entity's own equity instruments' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r140"
     ]
    },
    "ifrs-full_ClassesOfFinancialAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialAssetsAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of financial assets [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r164",
      "r188",
      "r189",
      "r209",
      "r210"
     ]
    },
    "ifrs-full_ClassesOfFinancialAssetsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialAssetsDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for aggregated classes of financial assets. It also represents the standard value for the 'Classes of financial assets' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r164",
      "r188",
      "r189",
      "r209",
      "r210"
     ]
    },
    "ifrs-full_ClassesOfFinancialInstrumentsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialInstrumentsAxis",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of financial instruments [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r181",
      "r184",
      "r185",
      "r186"
     ]
    },
    "ifrs-full_ClassesOfFinancialInstrumentsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialInstrumentsDomain",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for aggregated classes of financial instruments. Financial instruments are contracts that give rise to a financial asset of one entity and a financial liability or equity instrument of another entity. It also represents the standard value for the 'Classes of financial instruments' axis if no other member is used. [Refer: Financial assets; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r181",
      "r184",
      "r185",
      "r186"
     ]
    },
    "ifrs-full_ClassesOfFinancialLiabilitiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialLiabilitiesAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of financial liabilities [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r188",
      "r189",
      "r209",
      "r210"
     ]
    },
    "ifrs-full_ClassesOfFinancialLiabilitiesDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfFinancialLiabilitiesDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for aggregated classes financial liabilities. It also represents the standard value for the 'Classes of financial liabilities' axis if no other member is used. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r188",
      "r189",
      "r209",
      "r210"
     ]
    },
    "ifrs-full_ClassesOfIntangibleAssetsOtherThanGoodwillAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfIntangibleAssetsOtherThanGoodwillAxis",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of intangible assets other than goodwill [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r97"
     ]
    },
    "ifrs-full_ClassesOfIntangibleAssetsOtherThanGoodwillDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfIntangibleAssetsOtherThanGoodwillDomain",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Classes of intangible assets other than goodwill' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r97"
     ]
    },
    "ifrs-full_ClassesOfOtherProvisionsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfOtherProvisionsDomain",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for provisions other than provisions for employee benefits. It also represents the standard value for the 'Classes of other provisions' axis if no other member is used. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r92"
     ]
    },
    "ifrs-full_ClassesOfPropertyPlantAndEquipmentAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfPropertyPlantAndEquipmentAxis",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of property, plant and equipment [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r50"
     ]
    },
    "ifrs-full_ClassesOfPropertyPlantAndEquipmentDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfPropertyPlantAndEquipmentDomain",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Classes of property, plant and equipment' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r50"
     ]
    },
    "ifrs-full_ClassesOfProvisionsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfProvisionsAxis",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of other provisions [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r92"
     ]
    },
    "ifrs-full_ClassesOfShareCapitalAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfShareCapitalAxis",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes of share capital [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r29"
     ]
    },
    "ifrs-full_ClassesOfShareCapitalDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ClassesOfShareCapitalDomain",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for share capital of the entity. It also represents the standard value for the 'Classes of share capital' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r29"
     ]
    },
    "sbs_ClosingForeignExchangeRate1": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ClosingForeignExchangeRate1",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exchange rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ClosingForeignExchangeRateVariation": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ClosingForeignExchangeRateVariation",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exchange rate variation"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_CoSelectedMeasureAmt": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CoSelectedMeasureAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Company Selected Measure Amount"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "ecd_CoSelectedMeasureName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CoSelectedMeasureName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Company Selected Measure Name"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "sbs_CofinsForFinancialRevenuesRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CofinsForFinancialRevenuesRate",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cofins for financial revenues rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CommonAcquisitionShares": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CommonAcquisitionShares",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Common acquisition shares"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CommonPercentageOfShares": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CommonPercentageOfShares",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of shares, common"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CommonStockShareOutstanding": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CommonStockShareOutstanding",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital stock, shares"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_CompActuallyPaidVsCoSelectedMeasureTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CompActuallyPaidVsCoSelectedMeasureTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensation Actually Paid vs. Company Selected Measure"
       }
      }
     },
     "auth_ref": [
      "r331"
     ]
    },
    "ecd_CompActuallyPaidVsNetIncomeTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CompActuallyPaidVsNetIncomeTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensation Actually Paid vs. Net Income"
       }
      }
     },
     "auth_ref": [
      "r330"
     ]
    },
    "ecd_CompActuallyPaidVsOtherMeasureTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CompActuallyPaidVsOtherMeasureTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensation Actually Paid vs. Other Measure"
       }
      }
     },
     "auth_ref": [
      "r332"
     ]
    },
    "ecd_CompActuallyPaidVsTotalShareholderRtnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "CompActuallyPaidVsTotalShareholderRtnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensation Actually Paid vs. Total Shareholder Return"
       }
      }
     },
     "auth_ref": [
      "r329"
     ]
    },
    "sbs_ComplementaryMinimumDividendMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ComplementaryMinimumDividendMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Complementary Minimum Dividend [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ComplementaryMinimumDividends": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ComplementaryMinimumDividends",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Complementary minimum dividends (R$ 0.21607 per share)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ComplementaryMinimumDividendsApproved": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ComplementaryMinimumDividendsApproved",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Complementary minimum dividends of 2023, approved (R$ 0,14 per share)"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ComponentsOfEquityAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ComponentsOfEquityAxis",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Components of equity [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "ifrs-full_ComponentsOfEquityDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ComponentsOfEquityDomain",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the residual interest in the assets of the entity after deducting all its liabilities. It also represents the standard value for the 'Components of equity' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "ifrs-full_ComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity",
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total comprehensive income for the period",
        "label": "Total comprehensive income/(loss) for the period"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of change in equity resulting from transactions and other events, other than those changes resulting from transactions with owners in their capacity as owners."
       }
      }
     },
     "auth_ref": [
      "r2",
      "r31",
      "r120",
      "r124",
      "r131",
      "r239"
     ]
    },
    "ifrs-full_ComputerSoftware": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ComputerSoftware",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Software"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of intangible assets representing computer software. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r232"
     ]
    },
    "sbs_ConcessionAgreementMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConcessionAgreementMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession Agreement [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConcessionAgreementURAE1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConcessionAgreementURAE1Member",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession Agreement - URAE-1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConcessionAgreementsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConcessionAgreementsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concession Agreements [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConcessionariaSABESPURAE1SAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConcessionariaSABESPURAE1SAMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Concessionaria S A B E S P U R A E 1 S A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConsentDecreeTac": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConsentDecreeTac",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consent Decree (TAC)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConstructionCostsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConstructionCostsMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Construction Costs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ConstructionInProgressMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ConstructionInProgressMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Construction in progress [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for expenditure capitalised during the construction of items of property, plant and equipment that are not yet available for use (ie not yet in the location and condition necessary for it to be capable of operating in the manner intended by the management). [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r385"
     ]
    },
    "sbs_ConstructionMargin": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConstructionMargin",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Construction margin (Note 13)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ConstructionMarginMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ConstructionMarginMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Construction Margin [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_ContactPersonnelEmailAddress": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "ContactPersonnelEmailAddress",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contact Personnel Email Address",
        "documentation": "Email address of contact personnel."
       }
      }
     },
     "auth_ref": []
    },
    "dei_ContactPersonnelName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "ContactPersonnelName",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contact Personnel Name",
        "documentation": "Name of contact personnel"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractAssetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractAssetMember",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contract Asset [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractAssetTransfers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractAssetTransfers",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractAssetTransfersOfWorksToIntangibleAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractAssetTransfersOfWorksToIntangibleAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers of works to intangible assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ContractAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ContractAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Contract assets, beginning",
        "periodEndLabel": "Contract assets, ending",
        "label": "Contract assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of an entity\u2019s right to consideration in exchange for goods or services that the entity has transferred to a customer, when that right is conditioned on something other than the passage of time (for example, the entity\u2019s future performance)."
       }
      }
     },
     "auth_ref": [
      "r141",
      "r143"
     ]
    },
    "sbs_ContractAssetsWriteoffs": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractAssetsWriteoffs",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Write-offs",
        "label": "ContractAssetsWriteoffs"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractCommitmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractCommitmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contract Commitments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ContractLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ContractLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "Contract liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of an entity\u2019s obligation to transfer goods or services to a customer for which the entity has received consideration (or the amount is due) from the customer."
       }
      }
     },
     "auth_ref": [
      "r141",
      "r143"
     ]
    },
    "sbs_ContractLiabilitiesExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractLiabilitiesExpenses",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contractual obligations - expenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractLiabilitiesInvestments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractLiabilitiesInvestments",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contractual obligations - investments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContractorsPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContractorsPayable",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contractors payable"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContribuicaoParaOFinanciamentodaSeguridadeSocialMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContribuicaoParaOFinanciamentodaSeguridadeSocialMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contribuicao Para O Financiamentoda Seguridade Social [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContributionParticipants": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContributionParticipants",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contribution participants"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ContributionsAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ContributionsAmount",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contributions amount"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ContributionsToPlanByEmployerNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ContributionsToPlanByEmployerNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contributions of the Company and participants"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in net defined benefit liability (asset) resulting from contributions to a defined benefit plan by the employer. [Refer: Net defined benefit liability (asset); Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r58"
     ]
    },
    "ifrs-full_ContributionsToPlanByPlanParticipantsNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ContributionsToPlanByPlanParticipantsNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Participants contributions"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in the net defined benefit liability (asset) resulting from contributions to a defined benefit plan by plan participants. [Refer: Net defined benefit liability (asset); Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r58"
     ]
    },
    "ifrs-full_ContributionsToPlanNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ContributionsToPlanNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in the net defined benefit liability (asset) resulting from contributions to a defined benefit plan. [Refer: Net defined benefit liability (asset); Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r58"
     ]
    },
    "ifrs-full_CostOfSales": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CostOfSales",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_GrossProfit",
       "weight": -1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Operating costs",
        "negatedTerseLabel": "Cost of sales",
        "label": "Cost of sales"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of all expenses directly or indirectly attributed to the goods or services sold. Attributed expenses include, but are not limited to, costs previously included in the measurement of inventory that has now been sold, such as depreciation and maintenance of factory buildings and equipment used in the production process, unallocated production overheads, and abnormal amounts of production costs of inventories."
       }
      }
     },
     "auth_ref": [
      "r0",
      "r38"
     ]
    },
    "sbs_CostsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CostsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Costs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CostsOfExpropriationsRecordedInTheContractAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CostsOfExpropriationsRecordedInTheContractAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Costs of expropriations recorded in contract asset"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CounterpartiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CounterpartiesAxis",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparties [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r193"
     ]
    },
    "ifrs-full_CounterpartiesDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CounterpartiesDomain",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the parties to the transaction other than the entity. It also represents the standard value for the 'Counterparties' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r193"
     ]
    },
    "dei_CountryRegion": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "CountryRegion",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Country Region",
        "documentation": "Region code of country"
       }
      }
     },
     "auth_ref": []
    },
    "dei_CoverAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "CoverAbstract",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Cover page."
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CrossCurrencySwapMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CrossCurrencySwapMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cross Currency Swap [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_Currency": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Currency",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrencyInWhichInformationIsDisplayedAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrencyInWhichInformationIsDisplayedAxis",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency in which information is displayed [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r66"
     ]
    },
    "sbs_CurrencyOfDollarMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfDollarMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of Dollar [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrencyOfEUROMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfEUROMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of E U R O [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrencyOfIPCAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfIPCAMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of I P C A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrencyOfJPYMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfJPYMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of J P Y [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrencyOfUSDMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfUSDMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of U S D [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrencyOfUSDollarMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrencyOfUSDollarMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Of U S Dollar [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentAdvancesToSuppliers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentAdvancesToSuppliers",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Advances"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current advances made to suppliers before goods or services are received."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_CurrentAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total current assets",
        "label": "Current assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that the entity (a) expects to realise or intends to sell or consume in its normal operating cycle; (b) holds primarily for the purpose of trading; (c) expects to realise within twelve months after the reporting period; or (d) classifies as cash or cash equivalents (as defined in IAS 7) unless the asset is restricted from being exchanged or used to settle a liability for at least twelve months after the reporting period. [Refer: Assets]"
       }
      }
     },
     "auth_ref": [
      "r23",
      "r127",
      "r239"
     ]
    },
    "ifrs-full_CurrentAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentAssetsAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_CurrentFinancialAssetAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrentFinancialAssetAtAmortisedCost",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Financial investments",
        "label": "CurrentFinancialAssetAtAmortisedCost"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentFinancialAssetsAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentFinancialAssetsAtAmortisedCost",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails",
      "http://sabesp.com.br/role/RiskManagementDetails5",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial investments",
        "negatedLabel": "(-) Financial investments (Note 8)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current financial assets measured at amortised cost. [Refer: Financial assets at amortised cost]"
       }
      }
     },
     "auth_ref": [
      "r191"
     ]
    },
    "dei_CurrentFiscalYearEndDate": {
     "xbrltype": "gMonthDayItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "CurrentFiscalYearEndDate",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Fiscal Year End Date",
        "documentation": "End date of current fiscal year in the format --MM-DD."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentInterestPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentInterestPayable",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends and interest on capital payable"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current interest payable. [Refer: Interest payable]"
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_CurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total current liabilities",
        "label": "Current liabilities [Default Label]"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities that: (a) the entity expects to settle in its normal operating cycle; (b) the entity holds primarily for the purpose of trading; (c) are due to be settled within twelve months after the reporting period; or (d) the entity does not have the right at the end of the reporting period to defer settlement for at least twelve months after the reporting period."
       }
      }
     },
     "auth_ref": [
      "r24",
      "r129",
      "r239"
     ]
    },
    "ifrs-full_CurrentLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentLiabilitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a current time band."
       }
      }
     },
     "auth_ref": [
      "r246",
      "r255"
     ]
    },
    "ifrs-full_CurrentPortionOfLongtermBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentPortionOfLongtermBorrowings",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings and financing",
        "verboseLabel": "Current"
       }
      },
      "en": {
       "role": {
        "documentation": "The current portion of non-current borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_CurrentProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrentProvisionMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Provision [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentProvisions",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current provisions, including provisions for employee benefits. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r15"
     ]
    },
    "ifrs-full_CurrentProvisionsForEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentProvisionsForEmployeeBenefits",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Labor and social obligations"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current provisions for employee benefits. [Refer: Provisions for employee benefits]"
       }
      }
     },
     "auth_ref": [
      "r26"
     ]
    },
    "sbs_CurrentServiceCostEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CurrentServiceCostEmployeeBenefits",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cost of service, net"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentServiceCostNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentServiceCostNetDefinedBenefitLiabilityAsset",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest cost",
        "negatedLabel": "Current service cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in the net defined benefit liability (asset) resulting from employee service in the current period. [Refer: Net defined benefit liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r52"
     ]
    },
    "ifrs-full_CurrentTaxAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentTaxAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxes Recoverable",
        "verboseLabel": "Current tax assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The excess of amount paid for current tax in respect of current and prior periods over the amount due for those periods. Current tax is the amount of income taxes payable (recoverable) in respect of the taxable profit (tax loss) for a period."
       }
      }
     },
     "auth_ref": [
      "r16"
     ]
    },
    "ifrs-full_CurrentTaxExpenseIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentTaxExpenseIncome",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_IncomeTaxAndSocialContribution",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Current",
        "label": "Current tax expense (income)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income taxes payable (recoverable) in respect of the taxable profit (tax loss) for a period."
       }
      }
     },
     "auth_ref": [
      "r222"
     ]
    },
    "ifrs-full_CurrentTaxLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentTaxLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxes and contributions payable",
        "verboseLabel": "Current tax liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current tax for current and prior periods to the extent unpaid. Current tax is the amount of income taxes payable (recoverable) in respect of the taxable profit (tax loss) for a period."
       }
      }
     },
     "auth_ref": [
      "r16"
     ]
    },
    "ifrs-full_CurrentTradeReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "CurrentTradeReceivables",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition",
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trade receivables",
        "verboseLabel": "Current"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current trade receivables. [Refer: Trade receivables]"
       }
      }
     },
     "auth_ref": [
      "r217",
      "r218"
     ]
    },
    "sbs_CustomerClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "CustomerClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "cyd_CybersecurityRiskBoardCommitteeOrSubcommitteeResponsibleForOversightTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskBoardCommitteeOrSubcommitteeResponsibleForOversightTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Board Committee or Subcommittee Responsible for Oversight [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r280",
      "r365"
     ]
    },
    "cyd_CybersecurityRiskBoardOfDirectorsOversightTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskBoardOfDirectorsOversightTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Board of Directors Oversight [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r280",
      "r365"
     ]
    },
    "cyd_CybersecurityRiskManagementPositionsOrCommitteesResponsibleFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementPositionsOrCommitteesResponsibleFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Positions or Committees Responsible [Flag]"
       }
      }
     },
     "auth_ref": [
      "r282",
      "r367"
     ]
    },
    "cyd_CybersecurityRiskManagementPositionsOrCommitteesResponsibleReportToBoardFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementPositionsOrCommitteesResponsibleReportToBoardFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Positions or Committees Responsible Report to Board [Flag]"
       }
      }
     },
     "auth_ref": [
      "r284",
      "r369"
     ]
    },
    "cyd_CybersecurityRiskManagementPositionsOrCommitteesResponsibleTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementPositionsOrCommitteesResponsibleTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Positions or Committees Responsible [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r282",
      "r367"
     ]
    },
    "cyd_CybersecurityRiskManagementProcessesForAssessingIdentifyingAndManagingThreatsTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementProcessesForAssessingIdentifyingAndManagingThreatsTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Processes for Assessing, Identifying, and Managing Threats [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r275",
      "r360"
     ]
    },
    "cyd_CybersecurityRiskManagementProcessesIntegratedFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementProcessesIntegratedFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Processes Integrated [Flag]"
       }
      }
     },
     "auth_ref": [
      "r276",
      "r361"
     ]
    },
    "cyd_CybersecurityRiskManagementProcessesIntegratedTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementProcessesIntegratedTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Processes Integrated [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r276",
      "r361"
     ]
    },
    "cyd_CybersecurityRiskManagementStrategyAndGovernanceAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementStrategyAndGovernanceAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management, Strategy, and Governance [Abstract]"
       }
      }
     },
     "auth_ref": [
      "r274",
      "r359"
     ]
    },
    "cyd_CybersecurityRiskManagementThirdPartyEngagedFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskManagementThirdPartyEngagedFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Management Third Party Engaged [Flag]"
       }
      }
     },
     "auth_ref": [
      "r277",
      "r362"
     ]
    },
    "cyd_CybersecurityRiskMateriallyAffectedOrReasonablyLikelyToMateriallyAffectRegistrantFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskMateriallyAffectedOrReasonablyLikelyToMateriallyAffectRegistrantFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Materially Affected or Reasonably Likely to Materially Affect Registrant [Flag]"
       }
      }
     },
     "auth_ref": [
      "r279",
      "r364"
     ]
    },
    "cyd_CybersecurityRiskMateriallyAffectedOrReasonablyLikelyToMateriallyAffectRegistrantTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskMateriallyAffectedOrReasonablyLikelyToMateriallyAffectRegistrantTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Materially Affected or Reasonably Likely to Materially Affect Registrant [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r279",
      "r364"
     ]
    },
    "cyd_CybersecurityRiskProcessForInformingBoardCommitteeOrSubcommitteeResponsibleForOversightTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskProcessForInformingBoardCommitteeOrSubcommitteeResponsibleForOversightTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Process for Informing Board Committee or Subcommittee Responsible for Oversight [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r280",
      "r365"
     ]
    },
    "cyd_CybersecurityRiskProcessForInformingManagementOrCommitteesResponsibleTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskProcessForInformingManagementOrCommitteesResponsibleTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Process for Informing Management or Committees Responsible [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r283",
      "r368"
     ]
    },
    "cyd_CybersecurityRiskRoleOfManagementTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskRoleOfManagementTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Role of Management [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r281",
      "r366"
     ]
    },
    "cyd_CybersecurityRiskThirdPartyOversightAndIdentificationProcessesFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "CybersecurityRiskThirdPartyOversightAndIdentificationProcessesFlag",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cybersecurity Risk Third Party Oversight and Identification Processes [Flag]"
       }
      }
     },
     "auth_ref": [
      "r278",
      "r363"
     ]
    },
    "ifrs-full_DateOfGrantOfSharebasedPaymentArrangement": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DateOfGrantOfSharebasedPaymentArrangement",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Grant date"
       }
      },
      "en": {
       "role": {
        "documentation": "The date on which share-based payment arrangements are granted. [Refer: Types of share-based payment arrangements [domain]]"
       }
      }
     },
     "auth_ref": [
      "r243",
      "r244"
     ]
    },
    "sbs_Debentures1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Debentures1Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debentures 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_Debentures2Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Debentures2Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debentures 2 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DebtNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DebtNet",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net debt"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeclaredDividendPayables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeclaredDividendPayables",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Balance payable of interest on capital"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeclaredDividendPayables1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeclaredDividendPayables1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Declared dividend payables"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DecreaseOfOnePercentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DecreaseOfOnePercentMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Decrease Of One Percent [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DecreaseOfOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DecreaseOfOneYearMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Decrease Of One Year [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredCOFINSAndPASEP": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredCOFINSAndPASEP",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred PIS/Cofins",
        "verboseLabel": "Deferred non current liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredIncomeTaxAndSocialContributionNoncurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredIncomeTaxAndSocialContributionNoncurrent",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred income and social contribution taxes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredIncomeTaxAndSocialContributionPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredIncomeTaxAndSocialContributionPlan",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred income tax and social contribution - G1 Plan"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredPISCofinsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredPISCofinsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred P I S Cofins [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredPiscofinsOnFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredPiscofinsOnFinancialAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 17.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred PIS and Cofins on financial asset of the concession"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredPiscofinsTaxes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredPiscofinsTaxes",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred PIS/Cofins taxes",
        "verboseLabel": "Deferred current liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredTaxAssetChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxAssetChanges",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred tax asset, changes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredTaxAssetOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxAssetOther",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total deferred tax assets",
        "periodStartLabel": "Deferred income tax assets, beginning",
        "periodEndLabel": "Deferred income tax assets, ending",
        "label": "DeferredTaxAssetOther"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredTaxAssetOtherChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxAssetOtherChanges",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Deferred tax asset, changes",
        "label": "DeferredTaxAssetOtherChanges"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DeferredTaxAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total deferred tax assets",
        "verboseLabel": "Deferred income tax assets",
        "periodStartLabel": "Deferred income tax assets, beginning",
        "periodEndLabel": "Deferred income tax assets, ending"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts of income taxes recoverable in future periods in respect of: (a) deductible temporary differences; (b) the carryforward of unused tax losses; and (c) the carryforward of unused tax credits. [Refer: Temporary differences [member]; Unused tax credits [member]; Unused tax losses [member]]"
       }
      }
     },
     "auth_ref": [
      "r17",
      "r19",
      "r44"
     ]
    },
    "sbs_DeferredTaxAssetsNetChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxAssetsNetChanges",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred tax assets, net, changes"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxExpenseIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DeferredTaxExpenseIncome",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Deferred income and social contribution taxes",
        "label": "Deferred tax expense (income)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of tax expense (income) relating to changes in deferred tax liabilities and deferred tax assets. [Refer: Deferred tax assets; Deferred tax liabilities]"
       }
      }
     },
     "auth_ref": [
      "r45"
     ]
    },
    "ifrs-full_DeferredTaxExpenseIncomeRecognisedInProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DeferredTaxExpenseIncomeRecognisedInProfitOrLoss",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "- consideration in the income statement"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of tax expense or income relating to changes in deferred tax liabilities and deferred tax assets, recognised in profit or loss. [Refer: Deferred tax assets; Deferred tax expense (income); Deferred tax liabilities]"
       }
      }
     },
     "auth_ref": [
      "r45"
     ]
    },
    "sbs_DeferredTaxExpenseIncomes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxExpenseIncomes",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_IncomeTaxAndSocialContribution",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Deferred",
        "label": "DeferredTaxExpenseIncomes"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DeferredTaxLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Total deferred tax liabilities",
        "negatedTerseLabel": "Deferred income tax liabilities",
        "negatedPeriodStartLabel": "Deferred income tax liabilities, beginning",
        "negatedPeriodEndLabel": "Deferred income tax liabilities, ending",
        "label": "Deferred tax liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts of income taxes payable in future periods in respect of taxable temporary differences. [Refer: Temporary differences [member]]"
       }
      }
     },
     "auth_ref": [
      "r17",
      "r19",
      "r44"
     ]
    },
    "sbs_DeferredTaxLiabilitiesChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxLiabilitiesChanges",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred tax liabilities, changes"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DeferredTaxLiabilityAsset",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred tax assets (liabilities), net",
        "periodStartLabel": "Initial balance",
        "periodEndLabel": "Final balance"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of deferred tax liabilities or assets. [Refer: Deferred tax liabilities; Deferred tax assets]"
       }
      }
     },
     "auth_ref": [
      "r44"
     ]
    },
    "sbs_DeferredTaxesCorrespondingEntryToValuationAdjustmentsToEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxesCorrespondingEntryToValuationAdjustmentsToEquity",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "- consideration in equity valuation adjustments (Note 26)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DeferredTaxesOtherMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DeferredTaxesOtherMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Taxes Other [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DefinedBenefitObligationAtPresentValues": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DefinedBenefitObligationAtPresentValues",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Present value of defined benefit obligations",
        "periodStartLabel": "Defined benefit obligation, beginning",
        "periodEndLabel": "Defined benefit obligation, ending"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DefinedBenefitPlansAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DefinedBenefitPlansAxis",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Defined benefit plans [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r51"
     ]
    },
    "ifrs-full_DefinedBenefitPlansDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DefinedBenefitPlansDomain",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for post-employment benefit plans other than defined contribution plans. Defined contribution plans are post-employment benefit plans under which an entity pays fixed contributions into a separate entity (a fund) and will have no legal or constructive obligation to pay further contributions if the fund does not hold sufficient assets to pay all employee benefits relating to employee service in the current and prior periods. It also represents the standard value for the 'Defined benefit plans' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r51"
     ]
    },
    "ifrs-full_DepreciationAndAmortisationExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DepreciationAndAmortisationExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Depreciation and amortization",
        "negatedLabel": "Depreciation and amortization",
        "label": "Depreciation and amortisation expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of depreciation and amortisation expense. Depreciation and amortisation are the systematic allocations of depreciable amounts of assets over their useful lives."
       }
      }
     },
     "auth_ref": [
      "r1",
      "r38",
      "r134",
      "r197",
      "r205",
      "r214"
     ]
    },
    "sbs_DepreciationAndAmortizationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DepreciationAndAmortizationMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Depreciation And Amortization [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DepreciationExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DepreciationExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amortization"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of depreciation expense. Depreciation is the systematic allocation of depreciable amounts of tangible assets over their useful lives."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_DepreciationPropertyPlantAndEquipments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DepreciationPropertyPlantAndEquipments",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Depreciation"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DepreciationRightofuseAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DepreciationRightofuseAssets",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Right of use amortization",
        "label": "Depreciation, right-of-use assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of depreciation of right-of-use assets. [Refer: Depreciation and amortisation expense; Right-of-use assets]"
       }
      }
     },
     "auth_ref": [
      "r147"
     ]
    },
    "ifrs-full_DerivativeFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DerivativeFinancialAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_DerivativeFinancialInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DerivativeFinancialInstruments",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Derivative Financial Instruments",
        "label": "DerivativeFinancialInstruments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DerivativeFinancialInstrumentsProfitLossMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DerivativeFinancialInstrumentsProfitLossMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Instruments Profit Loss [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DerivativeFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DerivativeFinancialLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Derivative financial instruments",
        "label": "Liability position"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial liabilities classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_DerivativeTransactionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DerivativeTransactionsMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Transactions [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DerivativesNotDesignatedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DerivativesNotDesignatedMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivatives Not Designated [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DescriptionOfAccountingPolicyForBorrowingsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForBorrowingsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Borrowings and financing",
        "label": "Description of accounting policy for borrowings [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForContingentLiabilitiesAndContingentAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForContingentLiabilitiesAndContingentAssetsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contract Assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for contingent liabilities and contingent assets. [Refer: Classes of contingent liabilities [domain]; Description of nature of contingent assets]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForDeferredIncomeTaxExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Deferred taxes and contributions",
        "label": "Description of accounting policy for deferred income tax [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for deferred income tax. [Refer: Deferred tax expense (income)]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForDerivativeFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForDerivativeFinancialInstrumentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "derivative financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for derivative financial instruments. [Refer: Classes of financial instruments [domain]; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForDividendsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForDividendsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/EquityPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Equity",
        "label": "Description of accounting policy for dividends [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for dividends. Dividends are distributions of profits to holders of equity investments in proportion to their holdings of a particular class of capital."
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForFinanceIncomeAndCostsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForFinanceIncomeAndCostsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeexpenseNetPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial income"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for finance income and costs. [Refer: Finance income (cost)]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForFinancialAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForFinancialAssetsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "financial asset of the concession"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForFinancialInstrumentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial asset \u2013 Classification"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for financial instruments. [Refer: Classes of financial instruments [domain]]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForForeignCurrencyTranslationExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForForeignCurrencyTranslationExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/SummaryOfMaterialAccountingPolicyInformationPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign currency balance translation"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for foreign currency translation."
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "intangible assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for intangible assets and goodwill. [Refer: Intangible assets and goodwill]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForInvestmentInAssociates": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForInvestmentInAssociates",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "financial investments"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for investments in associates. [Refer: Total for all associates [member]]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForInvestmentsInJointVentures": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForInvestmentsInJointVentures",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Investments",
        "label": "Description of accounting policy for investments in joint ventures [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for investments in joint ventures. [Refer: Total for all joint ventures [member]]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "sbs_DescriptionOfAccountingPolicyForLaborAndSocialObligationsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfAccountingPolicyForLaborAndSocialObligationsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Labor and social obligations",
        "label": "DescriptionOfAccountingPolicyForLaborAndSocialObligationsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DescriptionOfAccountingPolicyForPensionPlanObligationsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfAccountingPolicyForPensionPlanObligationsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Pension plan obligations",
        "label": "DescriptionOfAccountingPolicyForPensionPlanObligationsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DescriptionOfAccountingPolicyForPropertyPlantAndEquipmentExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForPropertyPlantAndEquipmentExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Property, plant, and equipment",
        "label": "Description of accounting policy for property, plant and equipment [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for property, plant and equipment. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForProvisionsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForProvisionsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions",
        "label": "Description of accounting policy for provisions [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for provisions. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForRecognitionOfRevenue": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForRecognitionOfRevenue",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenuePolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Operating revenue",
        "label": "Description of accounting policy for recognition of revenue [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for recognising revenue. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForRestrictedCashAndCashEquivalentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForRestrictedCashAndCashEquivalentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Cash and cash equivalents",
        "label": "Description of accounting policy for restricted cash and cash equivalents [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for restricted cash and cash equivalents. [Refer: Restricted cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForSegmentReportingExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForSegmentReportingExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Operating segment information",
        "label": "Description of accounting policy for segment reporting [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for segment reporting."
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForTradeAndOtherReceivablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForTradeAndOtherReceivablesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade receivables",
        "label": "Description of accounting policy for trade and other receivables [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for trade and other receivables. [Refer: Trade and other receivables]"
       }
      }
     },
     "auth_ref": [
      "r378"
     ]
    },
    "sbs_DescriptionOfDefinedBenefitPlan": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfDefinedBenefitPlan",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description of defined benefit plan"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DescriptionOfDefinedBenefitPlan1": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfDefinedBenefitPlan1",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional description of defined benefit plan"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of recognized financial statements"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the known or reasonably estimable information relevant to assessing the possible impact that the application of a new IFRS, that has been issued but is not yet effective, will have."
       }
      }
     },
     "auth_ref": [
      "r117"
     ]
    },
    "sbs_DescriptionOfFinancing": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfFinancing",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfInitialApplicationOfStandardsOrInterpretationsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosures"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes in accounting practices and disclosures"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DescriptionOfLegalReserve": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DescriptionOfLegalReserve",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description of legal reserve"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DescriptionOfNatureOfChangeInAccountingPolicy": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfNatureOfChangeInAccountingPolicy",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the nature of a change in accounting policy related to an initial application of an IFRS. [Refer: IFRSs [member]]"
       }
      }
     },
     "auth_ref": [
      "r114"
     ]
    },
    "ifrs-full_DescriptionOfPresentationCurrency": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfPresentationCurrency",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Currency",
        "label": "Description of presentation currency"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the currency in which the financial statements are presented."
       }
      }
     },
     "auth_ref": [
      "r7",
      "r65"
     ]
    },
    "ifrs-full_DescriptionOfTransitionalProvisionsOfInitiallyAppliedIFRSThatMightHaveEffectOnFuturePeriods": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfTransitionalProvisionsOfInitiallyAppliedIFRSThatMightHaveEffectOnFuturePeriods",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Impact"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of transitional provisions related to an initial application of an IFRS that might have an effect on future periods. [Refer: IFRSs [member]]"
       }
      }
     },
     "auth_ref": [
      "r115"
     ]
    },
    "ifrs-full_DescriptionOfUsefulLifePropertyPlantAndEquipment": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfUsefulLifePropertyPlantAndEquipment",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Useful life"
       }
      },
      "en": {
       "role": {
        "documentation": "Description of useful life used for property, plant and equipment. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r47"
     ]
    },
    "ifrs-full_DescriptionOfVestingRequirementsForSharebasedPaymentArrangement": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DescriptionOfVestingRequirementsForSharebasedPaymentArrangement",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Vesting rights conditions"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the vesting requirements for a type of share-based payment arrangement that existed at any time during the period. An entity with substantially similar types of share-based payment arrangements may aggregate this information. [Refer: Types of share-based payment arrangements [domain]]"
       }
      }
     },
     "auth_ref": [
      "r165"
     ]
    },
    "ifrs-full_DilutedEarningsLossPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DilutedEarningsLossPerShare",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings per share - diluted (in reais)",
        "verboseLabel": "Diluted earnings per share (reais per share)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of profit (loss) attributable to ordinary equity holders of the parent entity (the numerator), divided by the weighted average number of ordinary shares outstanding during the period (the denominator), both adjusted for the effects of all dilutive potential ordinary shares. [Refer: Ordinary shares [member]; Weighted average [member]]"
       }
      }
     },
     "auth_ref": [
      "r83",
      "r84"
     ]
    },
    "ifrs-full_DilutedEarningsPerShareAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DilutedEarningsPerShareAbstract",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dilution effect arising from:"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureBorrowingsAndFinancingAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureBorrowingsAndFinancingAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings And Financing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureChangesInAccountingPracticesAndDisclosuresAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureChangesInAccountingPracticesAndDisclosuresAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes In Accounting Practices And Disclosures"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureContractAssetsAndOtherConcessionAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureContractAssetsAndOtherConcessionAssetsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Contract Assets And Other Concession Assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureDeferredPiscofinsTaxesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureDeferredPiscofinsTaxesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Piscofins Taxes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureDerivativeFinancialInstrumentsAndHedgingTransactionsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureDerivativeFinancialInstrumentsAndHedgingTransactionsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Instruments And Hedging Transactions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureEquityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureEquityAbstract",
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Equity"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureFinancialAssetOfConcessionAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureFinancialAssetOfConcessionAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Asset Of Concession"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureIntangibleAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureIntangibleAssetsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Intangible Assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureInvestmentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureInvestmentsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Investments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureLaborAndSocialObligationsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureLaborAndSocialObligationsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Labor And Social Obligations"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfAmountsToBeRecoveredOrSettledAfterTwelveMonthsForClassesOfAssetsAndLiabilitiesThatContainAmountsToBeRecoveredOrSettledBothNoMoreAndMoreThanTwelveMonthsAfterReportingDateTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfAmountsToBeRecoveredOrSettledAfterTwelveMonthsForClassesOfAssetsAndLiabilitiesThatContainAmountsToBeRecoveredOrSettledBothNoMoreAndMoreThanTwelveMonthsAfterReportingDateTable",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails",
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of amounts to be recovered or settled after twelve months for classes of assets and liabilities that contain amounts to be recovered or settled both no more and more than twelve months after reporting date [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to amounts to be recovered or settled after twelve months for classes of assets and liabilities that contain amounts to be recovered or settled both no more, and more than, twelve months after reporting date."
       }
      }
     },
     "auth_ref": [
      "r22"
     ]
    },
    "ifrs-full_DisclosureOfBasisOfConsolidationExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfBasisOfConsolidationExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/SummaryOfMaterialAccountingPolicyInformationPolicies"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the basis used for consolidation."
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/BasisOfPreparationAndPresentationOfFinancialStatements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Basis of preparation and presentation of the financial statements"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the basis used for the preparation of the financial statements."
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "sbs_DisclosureOfBorrowingsAndFinancingExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfBorrowingsAndFinancingExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancing"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Borrowings and financing",
        "label": "DisclosureOfBorrowingsAndFinancingExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfCashAndCashEquivalentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfCashAndCashEquivalentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalents"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Cash and cash equivalents",
        "label": "Disclosure of cash and cash equivalents [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of cash and cash equivalents. [Refer: Cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfChangesInAccountingEstimatesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfChangesInAccountingEstimatesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/SignificantAccountingEstimatesAndJudgments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Significant accounting estimates and judgments"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of changes in accounting estimates."
       }
      }
     },
     "auth_ref": [
      "r118"
     ]
    },
    "ifrs-full_DisclosureOfCommitmentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfCommitmentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Commitments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commitments"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of commitments."
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "sbs_DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssets"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Contract assets and other concession assets",
        "label": "DisclosureOfContractAssetsAndOtherConcessionAssetsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfCreditRiskExposureTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfCreditRiskExposureTable",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of credit risk exposure [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the credit risk exposure."
       }
      }
     },
     "auth_ref": [
      "r185"
     ]
    },
    "sbs_DisclosureOfDeferredPISAndCofinsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfDeferredPISAndCofinsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxes"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Deferred PIS/Cofins taxes",
        "label": "DisclosureOfDeferredPISAndCofinsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfDeferredTaxesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfDeferredTaxesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred taxes and contributions"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of deferred taxes. [Refer: Deferred tax liabilities; Deferred tax assets]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfDefinedBenefitPlansTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfDefinedBenefitPlansTable",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of defined benefit plans [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to defined benefit plans."
       }
      }
     },
     "auth_ref": [
      "r51"
     ]
    },
    "sbs_DisclosureOfDerivativeFinancialsInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfDerivativeFinancialsInstrumentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative financial instruments and hedging transactions"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfDetailedInformationAboutBorrowingsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfDetailedInformationAboutBorrowingsTable",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of detailed information about borrowings [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to details of borrowings."
       }
      }
     },
     "auth_ref": [
      "r403"
     ]
    },
    "ifrs-full_DisclosureOfDisaggregationOfRevenueFromContractsWithCustomersTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfDisaggregationOfRevenueFromContractsWithCustomersTable",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of disaggregation of revenue from contracts with customers [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the disaggregation of revenue from contracts with customers."
       }
      }
     },
     "auth_ref": [
      "r142"
     ]
    },
    "ifrs-full_DisclosureOfEarningsPerShareExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfEarningsPerShareExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShare"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings per share"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for earnings per share."
       }
      }
     },
     "auth_ref": [
      "r86"
     ]
    },
    "sbs_DisclosureOfEmployeeBenefitExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfEmployeeBenefitExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Labor and social obligations",
        "label": "DisclosureOfEmployeeBenefitExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfEventsAfterReportingPeriodExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfEventsAfterReportingPeriodExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriod"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Events after the reporting period"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for events after the reporting period."
       }
      }
     },
     "auth_ref": [
      "r40"
     ]
    },
    "ifrs-full_DisclosureOfExpensesByNatureExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfExpensesByNatureExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpenses"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating costs and expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of expenses by nature. [Refer: Expenses, by nature]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfAssetsTable",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of fair value measurement of assets [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the fair value measurement of assets."
       }
      }
     },
     "auth_ref": [
      "r140"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfEquityTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfEquityTable",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of fair value measurement of equity [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the fair value measurement of equity."
       }
      }
     },
     "auth_ref": [
      "r140"
     ]
    },
    "ifrs-full_DisclosureOfFinanceIncomeExpenseExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFinanceIncomeExpenseExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeexpenseNet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial income/(expense), net"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of finance income (cost). [Refer: Finance income (cost)]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "sbs_DisclosureOfFinancialAssetIndemnityExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfFinancialAssetIndemnityExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcession"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Financial asset of the concession",
        "label": "DisclosureOfFinancialAssetIndemnityExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFinancialAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFinancialAssetsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Financial investments",
        "label": "Disclosure of financial assets [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r190"
     ]
    },
    "ifrs-full_DisclosureOfFinancialInstrumentsByTypeOfInterestRateTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFinancialInstrumentsByTypeOfInterestRateTable",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of financial instruments by type of interest rate [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to financial instruments, by type of interest rate."
       }
      }
     },
     "auth_ref": [
      "r402"
     ]
    },
    "ifrs-full_DisclosureOfFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFinancialInstrumentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstruments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for financial instruments."
       }
      }
     },
     "auth_ref": [
      "r195"
     ]
    },
    "ifrs-full_DisclosureOfFinancialInstrumentsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfFinancialInstrumentsTable",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of detailed information about financial instruments [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to details of financial instruments."
       }
      }
     },
     "auth_ref": [
      "r178",
      "r184",
      "r190"
     ]
    },
    "sbs_DisclosureOfIntangibleAssetExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfIntangibleAssetExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssets"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Intangible assets",
        "label": "DisclosureOfIntangibleAssetExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfIntangibleAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfIntangibleAssetsTable",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of detailed information about intangible assets [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to details of intangible assets."
       }
      }
     },
     "auth_ref": [
      "r97"
     ]
    },
    "ifrs-full_DisclosureOfInvestmentPropertyTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfInvestmentPropertyTable",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of detailed information about investment property [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to details of investment property."
       }
      }
     },
     "auth_ref": [
      "r99"
     ]
    },
    "sbs_DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Investments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Investments",
        "label": "DisclosureOfInvestmentsAccountedUsingEquityMethodExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOfIssuedCapitalsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfIssuedCapitalsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Equity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Equity",
        "label": "DisclosureOfIssuedCapitalsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfLiquidityRiskExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfLiquidityRiskExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of liquidity risk"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of liquidity risk. [Refer: Liquidity risk [member]]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfMaterialAccountingPolicyInformationExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfMaterialAccountingPolicyInformationExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/SummaryOfMaterialAccountingPolicyInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Summary of material accounting policy information"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure of material accounting policy information applied by the entity."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ifrs-full_DisclosureOfNonadjustingEventsAfterReportingPeriodTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfNonadjustingEventsAfterReportingPeriodTable",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of non-adjusting events after reporting period [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to non-adjusting events after the reporting period."
       }
      }
     },
     "auth_ref": [
      "r39"
     ]
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialAssetsTable",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of offsetting of financial assets [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the offsetting of financial assets."
       }
      }
     },
     "auth_ref": [
      "r171"
     ]
    },
    "sbs_DisclosureOfOperatingSegmentExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfOperatingSegmentExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating segment information"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOfOperationsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfOperationsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Operations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Operations",
        "label": "DisclosureOfOperationsExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfOtherLiabilitiesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayable"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Services payable",
        "label": "Disclosure of other liabilities [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of other liabilities. [Refer: Other liabilities]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "sbs_DisclosureOfOtherOperatingIncomeExpensesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfOtherOperatingIncomeExpensesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other operating income (expenses), net",
        "label": "DisclosureOfOtherOperatingIncomeExpensesExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherProvisionsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfOtherProvisionsTable",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of other provisions [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to other provisions."
       }
      }
     },
     "auth_ref": [
      "r92"
     ]
    },
    "sbs_DisclosureOfPensionPlanLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfPensionPlanLiabilitiesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Pension plan obligations",
        "label": "DisclosureOfPensionPlanLiabilitiesExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfPropertyPlantAndEquipmentTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfPropertyPlantAndEquipmentTable",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of detailed information about property, plant and equipment [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to details of property, plant and equipment."
       }
      }
     },
     "auth_ref": [
      "r50"
     ]
    },
    "sbs_DisclosureOfPropertyPlantAndEquipmentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfPropertyPlantAndEquipmentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipment"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Property, plant, and equipment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOfProvisionExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfProvisionExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Provisions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions",
        "label": "DisclosureOfProvisionExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfProvisionMatrixTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfProvisionMatrixTable",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of provision matrix [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the provision matrix."
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "ifrs-full_DisclosureOfReclassificationOfFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfReclassificationOfFinancialInstrumentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the reclassification of financial instruments. [Refer: Classes of financial instruments [domain]]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfRelatedPartyExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfRelatedPartyExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Related-party balances and transactions",
        "label": "Disclosure of related party [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for related parties."
       }
      }
     },
     "auth_ref": [
      "r74"
     ]
    },
    "ifrs-full_DisclosureOfRestrictedCashAndCashEquivalentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfRestrictedCashAndCashEquivalentsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/RestrictedCash"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Restricted cash",
        "label": "Disclosure of restricted cash and cash equivalents [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of restricted cash and cash equivalents. [Refer: Restricted cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "sbs_DisclosureOfRevenuesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfRevenuesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenue"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Operating revenue",
        "label": "DisclosureOfRevenuesExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOfRiskManagementExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfRiskManagementExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Risk management"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfSensitivityAnalysisForActuarialAssumptionsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfSensitivityAnalysisForActuarialAssumptionsTable",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of sensitivity analysis for actuarial assumptions [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the sensitivity analysis for actuarial assumptions."
       }
      }
     },
     "auth_ref": [
      "r61"
     ]
    },
    "ifrs-full_DisclosureOfServiceConcessionArrangementsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfServiceConcessionArrangementsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of other concession assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for service concession arrangements."
       }
      }
     },
     "auth_ref": [
      "r212"
     ]
    },
    "sbs_DisclosureOfSupplementalCashFlowInformationExplanatoryOne": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfSupplementalCashFlowInformationExplanatoryOne",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Supplemental cash flow information"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfTaxReceivablesAndPayablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfTaxReceivablesAndPayablesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxes and Contributions"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of tax receivables and payables."
       }
      }
     },
     "auth_ref": [
      "r374"
     ]
    },
    "ifrs-full_DisclosureOfTemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfTemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsTable",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of temporary difference, unused tax losses and unused tax credits [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to temporary differences, unused tax losses and unused tax credits."
       }
      }
     },
     "auth_ref": [
      "r46"
     ]
    },
    "sbs_DisclosureOfTradeAndOtherReceivableExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOfTradeAndOtherReceivableExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade receivables",
        "label": "DisclosureOfTradeAndOtherReceivableExplanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfTransactionsBetweenRelatedPartiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfTransactionsBetweenRelatedPartiesExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of expenses related to the compensation"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of transactions between the entity and its related parties. [Refer: Total for all related parties [member]]"
       }
      }
     },
     "auth_ref": [
      "r71"
     ]
    },
    "ifrs-full_DisclosureOfTransactionsBetweenRelatedPartiesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisclosureOfTransactionsBetweenRelatedPartiesTable",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9",
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/IntangibleAssetsDetails4",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of transactions between related parties [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to transactions between related parties."
       }
      }
     },
     "auth_ref": [
      "r72"
     ]
    },
    "sbs_DisclosureOperatingRevenueAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOperatingRevenueAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating Revenue"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOperatingSegmentInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOperatingSegmentInformationAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating Segment Information"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOperationsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOperationsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Operations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureOtherOperatingIncomeExpensesNetAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureOtherOperatingIncomeExpensesNetAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Operating Income Expenses Net"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosurePensionPlanObligationsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosurePensionPlanObligationsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension Plan Obligations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosurePropertyPlantAndEquipmentAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosurePropertyPlantAndEquipmentAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Property Plant And Equipment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureProvisionsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureProvisionsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureRiskManagementAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureRiskManagementAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Risk Management"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureSupplementalCashFlowInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureSupplementalCashFlowInformationAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Supplemental Cash Flow Information"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DisclosureTradeReceivablesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisclosureTradeReceivablesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Trade Receivables"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DiscountRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DiscountRateMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Discount Rate [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisposalsIntangibleAssetsOtherThanGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DisposalsIntangibleAssetsOtherThanGoodwill",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Write-offs and disposals",
        "label": "Disposals, intangible assets other than goodwill"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in intangible assets other than goodwill resulting from disposals. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r94"
     ]
    },
    "sbs_DisputedAmountsReceivable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DisputedAmountsReceivable",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disputed amounts receivable"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DividendPayables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendPayables",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Dividends and interest on capital payable",
        "label": "Dividend payables"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of dividends that the company has declared but not yet paid."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_DividendsDistributed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DividendsDistributed",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends distributed"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DividendsDistributed1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DividendsDistributed1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Dividends distributed",
        "label": "DividendsDistributed1"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DividendsInterestOnEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DividendsInterestOnEquity",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends interest on equity"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DividendsPaid": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendsPaid",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Dividends for the year (R$\u00a01,05 per share)",
        "label": "Dividends recognised as distributions to owners"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of dividends recognised as distributions to owners."
       }
      }
     },
     "auth_ref": [
      "r5"
     ]
    },
    "ifrs-full_DividendsPaidClassifiedAsFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendsPaidClassifiedAsFinancingActivities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Payment of interest on capital",
        "label": "Dividends paid, classified as financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for dividends paid by the entity, classified as financing activities."
       }
      }
     },
     "auth_ref": [
      "r107"
     ]
    },
    "ifrs-full_DividendsPaidClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendsPaidClassifiedAsOperatingActivities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends paid, classified as operating activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for dividends paid by the entity, classified as operating activities."
       }
      }
     },
     "auth_ref": [
      "r107"
     ]
    },
    "ifrs-full_DividendsPaidOrdinarySharesPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendsPaidOrdinarySharesPerShare",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends paid, ordinary shares per share"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of dividends paid per ordinary share."
       }
      }
     },
     "auth_ref": [
      "r87"
     ]
    },
    "ifrs-full_DividendsReceived": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "DividendsReceived",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends received"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of dividends received."
       }
      }
     },
     "auth_ref": [
      "r126"
     ]
    },
    "sbs_DividendsWitheldIncomeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DividendsWitheldIncomeTax",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends witheld income tax"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DividendsWitheldIncomeTax1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DividendsWitheldIncomeTax1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends witheld income tax, net"
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentAccountingStandard": {
     "xbrltype": "accountingStandardItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentAccountingStandard",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Accounting Standard",
        "documentation": "The basis of accounting the registrant has used to prepare the financial statements included in this filing This can either be 'U.S. GAAP', 'International Financial Reporting Standards', or 'Other'."
       }
      }
     },
     "auth_ref": [
      "r272"
     ]
    },
    "dei_DocumentAnnualReport": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentAnnualReport",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Annual Report",
        "documentation": "Boolean flag that is true only for a form used as an annual report."
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295"
     ]
    },
    "dei_DocumentFinStmtErrorCorrectionFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentFinStmtErrorCorrectionFlag",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Financial Statement Error Correction [Flag]",
        "documentation": "Indicates whether any of the financial statement period in the filing include a restatement due to error correction."
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295",
      "r335"
     ]
    },
    "dei_DocumentFiscalPeriodFocus": {
     "xbrltype": "fiscalPeriodItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentFiscalPeriodFocus",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Fiscal Period Focus",
        "documentation": "Fiscal period values are FY, Q1, Q2, and Q3. 1st, 2nd and 3rd quarter 10-Q or 10-QT statements have value Q1, Q2, and Q3 respectively, with 10-K, 10-KT or other fiscal year statements having FY."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentFiscalYearFocus": {
     "xbrltype": "gYearItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentFiscalYearFocus",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Fiscal Year Focus",
        "documentation": "This is focus fiscal year of the document report in YYYY format. For a 2006 annual report, which may also provide financial information from prior periods, fiscal 2006 should be given as the fiscal year focus. Example: 2006."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentPeriodEndDate": {
     "xbrltype": "dateItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentPeriodEndDate",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Period End Date",
        "documentation": "For the EDGAR submission types of Form 8-K: the date of the report, the date of the earliest event reported; for the EDGAR submission types of Form N-1A: the filing date; for all other submission types: the end of the reporting or transition period. The format of the date is YYYY-MM-DD."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentPeriodStartDate": {
     "xbrltype": "dateItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentPeriodStartDate",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Period Start Date",
        "documentation": "The start date of the period covered in the document, in YYYY-MM-DD format."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentQuarterlyReport": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentQuarterlyReport",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Quarterly Report",
        "documentation": "Boolean flag that is true only for a form used as an quarterly report."
       }
      }
     },
     "auth_ref": [
      "r271"
     ]
    },
    "dei_DocumentRegistrationStatement": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentRegistrationStatement",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Registration Statement",
        "documentation": "Boolean flag that is true only for a form used as a registration statement."
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "dei_DocumentShellCompanyEventDate": {
     "xbrltype": "dateItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentShellCompanyEventDate",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Shell Company Event Date",
        "documentation": "Date of event requiring a shell company report."
       }
      }
     },
     "auth_ref": [
      "r272"
     ]
    },
    "dei_DocumentShellCompanyReport": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentShellCompanyReport",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Shell Company Report",
        "documentation": "Boolean flag that is true for a Shell Company Report pursuant to section 13 or 15(d) of the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r272"
     ]
    },
    "dei_DocumentTransitionReport": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentTransitionReport",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Transition Report",
        "documentation": "Boolean flag that is true only for a form used as a transition report."
       }
      }
     },
     "auth_ref": [
      "r320"
     ]
    },
    "dei_DocumentType": {
     "xbrltype": "submissionTypeItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentType",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Type",
        "documentation": "The type of document being provided (such as 10-K, 10-Q, 485BPOS, etc). The document type is limited to the same value as the supporting SEC submission type, or the word 'Other'."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentsIncorporatedByReferenceTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "DocumentsIncorporatedByReferenceTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Documents Incorporated by Reference [Text Block]",
        "documentation": "Documents incorporated by reference."
       }
      }
     },
     "auth_ref": [
      "r262"
     ]
    },
    "sbs_DollarMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DollarMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dollar [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_DonationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "DonationsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Donations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EBITDAFinancialExpensesPaidMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EBITDAFinancialExpensesPaidMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "EBITDA / Financial Expenses Paid [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EffectOfExchangeRateChangesOnBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EffectOfExchangeRateChangesOnBorrowings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflation adjustment and exchange rate changes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EffectsOnProfitForTheYearBeforeTaxes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EffectsOnProfitForTheYearBeforeTaxes",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Effects on profit for the year before taxes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ElectricityOneMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ElectricityOneMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Electricity One [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressAddressLine1": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressAddressLine1",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, Address Line One",
        "documentation": "Address Line 1 such as Attn, Building Name, Street Name"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressAddressLine2": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressAddressLine2",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, Address Line Two",
        "documentation": "Address Line 2 such as Street or Suite number"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressAddressLine3": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressAddressLine3",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, Address Line Three",
        "documentation": "Address Line 3 such as an Office Park"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressCityOrTown": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressCityOrTown",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, City or Town",
        "documentation": "Name of the City or Town"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressCountry": {
     "xbrltype": "countryCodeItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressCountry",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, Country",
        "documentation": "ISO 3166-1 alpha-2 country code."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressPostalZipCode": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressPostalZipCode",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, Postal Zip Code",
        "documentation": "Code for the postal or zip code"
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressStateOrProvince": {
     "xbrltype": "stateOrProvinceItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressStateOrProvince",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Address, State or Province",
        "documentation": "Name of the state or province."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressesAddressTypeAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressesAddressTypeAxis",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Addresses, Address Type [Axis]",
        "documentation": "The axis of a table defines the relationship between the domain members or categories in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressesLineItems",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Addresses [Line Items]",
        "documentation": "Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityAddressesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityAddressesTable",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Addresses [Table]",
        "documentation": "Container of address information for the entity"
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityBankruptcyProceedingsReportingCurrent": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityBankruptcyProceedingsReportingCurrent",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Bankruptcy Proceedings, Reporting Current",
        "documentation": "For registrants involved in bankruptcy proceedings during the preceding five years, the value Yes indicates that the registrant has filed all documents and reports required to be filed by Section 12, 13 or 15(d) of the Securities Exchange Act of 1934 subsequent to the distribution of securities under a plan confirmed by a court; the value No indicates the registrant has not. Registrants not involved in bankruptcy proceedings during the preceding five years should not report this element."
       }
      }
     },
     "auth_ref": [
      "r265"
     ]
    },
    "dei_EntityCentralIndexKey": {
     "xbrltype": "centralIndexKeyItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityCentralIndexKey",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Central Index Key",
        "documentation": "A unique 10-digit SEC-issued value to identify entities that have filed disclosures with the SEC. It is commonly abbreviated as CIK."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityCommonStockSharesOutstanding": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityCommonStockSharesOutstanding",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Common Stock, Shares Outstanding",
        "documentation": "Indicate number of shares or other units outstanding of each of registrant's classes of capital or common stock or other ownership interests, if and as stated on cover of related periodic report. Where multiple classes or units exist define each class/interest by adding class of stock items such as Common Class A [Member], Common Class B [Member] or Partnership Interest [Member] onto the Instrument [Domain] of the Entity Listings, Instrument."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityCurrentReportingStatus": {
     "xbrltype": "yesNoItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityCurrentReportingStatus",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Current Reporting Status",
        "documentation": "Indicate 'Yes' or 'No' whether registrants (1) have filed all reports required to be filed by Section 13 or 15(d) of the Securities Exchange Act of 1934 during the preceding 12 months (or for such shorter period that registrants were required to file such reports), and (2) have been subject to such filing requirements for the past 90 days. This information should be based on the registrant's current or most recent filing containing the related disclosure."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityEmergingGrowthCompany": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityEmergingGrowthCompany",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Emerging Growth Company",
        "documentation": "Indicate if registrant meets the emerging growth company criteria."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityExTransitionPeriod": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityExTransitionPeriod",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Elected Not To Use the Extended Transition Period",
        "documentation": "Indicate if an emerging growth company has elected not to use the extended transition period for complying with any new or revised financial accounting standards."
       }
      }
     },
     "auth_ref": [
      "r373"
     ]
    },
    "dei_EntityFileNumber": {
     "xbrltype": "fileNumberItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityFileNumber",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity File Number",
        "documentation": "Commission file number. The field allows up to 17 characters. The prefix may contain 1-3 digits, the sequence number may contain 1-8 digits, the optional suffix may contain 1-4 characters, and the fields are separated with a hyphen."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityFilerCategory": {
     "xbrltype": "filerCategoryItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityFilerCategory",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Filer Category",
        "documentation": "Indicate whether the registrant is one of the following: Large Accelerated Filer, Accelerated Filer, Non-accelerated Filer. Definitions of these categories are stated in Rule 12b-2 of the Exchange Act. This information should be based on the registrant's current or most recent filing containing the related disclosure."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityIncorporationStateCountryCode": {
     "xbrltype": "edgarStateCountryItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityIncorporationStateCountryCode",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Incorporation, State or Country Code",
        "documentation": "Two-character EDGAR code representing the state or country of incorporation."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityInteractiveDataCurrent": {
     "xbrltype": "yesNoItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityInteractiveDataCurrent",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Interactive Data Current",
        "documentation": "Boolean flag that is true when the registrant has submitted electronically every Interactive Data File required to be submitted pursuant to Rule 405 of Regulation S-T during the preceding 12 months (or for such shorter period that the registrant was required to submit such files)."
       }
      }
     },
     "auth_ref": [
      "r370"
     ]
    },
    "dei_EntityPrimarySicNumber": {
     "xbrltype": "sicNumberItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityPrimarySicNumber",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Primary SIC Number",
        "documentation": "Primary Standard Industrial Classification (SIC) Number for the Entity."
       }
      }
     },
     "auth_ref": [
      "r295"
     ]
    },
    "dei_EntityPublicFloat": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityPublicFloat",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Public Float",
        "documentation": "The aggregate market value of the voting and non-voting common equity held by non-affiliates computed by reference to the price at which the common equity was last sold, or the average bid and asked price of such common equity, as of the last business day of the registrant's most recently completed second fiscal quarter."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityRegistrantName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityRegistrantName",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Registrant Name",
        "documentation": "The exact name of the entity filing the report as specified in its charter, which is required by forms filed with the SEC."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityShellCompany": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityShellCompany",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Shell Company",
        "documentation": "Boolean flag that is true when the registrant is a shell company as defined in Rule 12b-2 of the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntitySmallBusiness": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntitySmallBusiness",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Small Business",
        "documentation": "Indicates that the company is a Smaller Reporting Company (SRC)."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityTaxIdentificationNumber": {
     "xbrltype": "employerIdItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityTaxIdentificationNumber",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Tax Identification Number",
        "documentation": "The Tax Identification Number (TIN), also known as an Employer Identification Number (EIN), is a unique 9-digit value assigned by the IRS."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "dei_EntityVoluntaryFilers": {
     "xbrltype": "yesNoItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityVoluntaryFilers",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Voluntary Filers",
        "documentation": "Indicate 'Yes' or 'No' if the registrant is not required to file reports pursuant to Section 13 or Section 15(d) of the Act."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityWellKnownSeasonedIssuer": {
     "xbrltype": "yesNoItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "EntityWellKnownSeasonedIssuer",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Well-known Seasoned Issuer",
        "documentation": "Indicate 'Yes' or 'No' if the registrant is a well-known seasoned issuer, as defined in Rule 405 of the Securities Act. Is used on Form Type: 10-K, 10-Q, 8-K, 20-F, 6-K, 10-K/A, 10-Q/A, 20-F/A, 6-K/A, N-CSR, N-Q, N-1A."
       }
      }
     },
     "auth_ref": [
      "r371"
     ]
    },
    "sbs_EnvironmentalClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EnvironmentalClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Environmental Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EquatorialS.AMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EquatorialS.AMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equatorial S. A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Equity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Equity",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_EquityAndLiabilities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/RiskManagementDetails5",
      "http://sabesp.com.br/role/StatementOfChangesInEquity",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total equity",
        "periodStartLabel": "Beginning balance, value",
        "periodEndLabel": "Ending balance, value",
        "label": "Total Equity",
        "verboseLabel": "Equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of residual interest in the assets of the entity after deducting all its liabilities."
       }
      }
     },
     "auth_ref": [
      "r18",
      "r27",
      "r119",
      "r123",
      "r137",
      "r138",
      "r139"
     ]
    },
    "ifrs-full_EquityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EquityAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EquityAndLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EquityAndLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total Liabilities and Equity",
        "label": "Equity and liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of the entity's equity and liabilities. [Refer: Equity; Liabilities]"
       }
      }
     },
     "auth_ref": [
      "r18"
     ]
    },
    "sbs_EquityInResultsOfInvestmentsInAffiliates": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EquityInResultsOfInvestmentsInAffiliates",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity in the earnings of subsidiaries"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EquityInResultsOfInvestmentsInAffiliaties": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EquityInResultsOfInvestmentsInAffiliaties",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity accounting"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EquityInstrumentsAmountContributedToFairValueOfPlanAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EquityInstrumentsAmountContributedToFairValueOfPlanAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total equities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount instruments representing equity (rather than debt) contribute to the fair value of defined benefit plan assets. [Refer: Plan assets, at fair value; Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r227"
     ]
    },
    "ifrs-full_EquityInterestsOfAcquirer": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EquityInterestsOfAcquirer",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consideration acquired"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value, at the acquisition date, of equity interests of the acquirer transferred as consideration in a business combination. [Refer: Total for all business combinations [member]]"
       }
      }
     },
     "auth_ref": [
      "r168"
     ]
    },
    "sbs_EquityValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EquityValuationAdjustments",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity valuation adjustments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EquityValuationAdjustmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EquityValuationAdjustmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Valuation Adjustments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_EquityValuationAssumptionDifferenceFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "EquityValuationAssumptionDifferenceFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Valuation Assumption Difference, Footnote"
       }
      }
     },
     "auth_ref": [
      "r328"
     ]
    },
    "ecd_ErrCompAnalysisTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ErrCompAnalysisTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Erroneous Compensation Analysis"
       }
      }
     },
     "auth_ref": [
      "r288",
      "r299",
      "r313",
      "r339"
     ]
    },
    "ecd_ErrCompRecoveryTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ErrCompRecoveryTable",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Erroneously Awarded Compensation Recovery [Table]"
       }
      }
     },
     "auth_ref": [
      "r285",
      "r296",
      "r310",
      "r336"
     ]
    },
    "sbs_EscrowDepositMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EscrowDepositMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Escrow Deposit [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_EstimateOfContributionExpectedToBePaidToPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EstimateOfContributionExpectedToBePaidToPlan",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cost of services, net"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EstimateOfContributionsExpectedToBePaidToPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EstimateOfContributionsExpectedToBePaidToPlan",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest costs"
       }
      },
      "en": {
       "role": {
        "documentation": "The estimate of the expected contributions to be made to a defined benefit plan for the next annual reporting period. [Refer: Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r62",
      "r63"
     ]
    },
    "sbs_EstimateOfContributionsExpectedToBePaidToPlanByCompany": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EstimateOfContributionsExpectedToBePaidToPlanByCompany",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Companys contributions"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EstimatedFinancialEffectOfContingentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "EstimatedFinancialEffectOfContingentLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Significant contingent liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of the estimated financial effect of contingent liabilities. [Refer: Classes of contingent liabilities [domain]]"
       }
      }
     },
     "auth_ref": [
      "r93"
     ]
    },
    "sbs_EuroMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "EuroMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Euro [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExchangeRateChangesBorrowingFinancingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExchangeRateChangesBorrowingFinancingMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exchange Rate Changes Borrowing Financing [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExchangeRateChangesOnAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExchangeRateChangesOnAssetsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exchange Rate Changes On Assets [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_ExecutiveCategoryAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ExecutiveCategoryAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Executive Category [Axis]"
       }
      }
     },
     "auth_ref": [
      "r334"
     ]
    },
    "sbs_ExistingShares": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExistingShares",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Existing shares"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExpectedDividendAsPercentageShareOptionsGranted": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ExpectedDividendAsPercentageShareOptionsGranted",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Yield percentage"
       }
      },
      "en": {
       "role": {
        "documentation": "The percentage of an expected dividend used to calculate the fair value of share options granted."
       }
      }
     },
     "auth_ref": [
      "r166"
     ]
    },
    "ifrs-full_ExpenseByNature": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ExpenseByNature",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4",
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General expenses",
        "negatedLabel": "Expenses, by nature"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expenses aggregated according to their nature (for example, depreciation, purchases of materials, transport costs, employee benefits and advertising costs), and not reallocated among functions within the entity."
       }
      }
     },
     "auth_ref": [
      "r38"
     ]
    },
    "sbs_ExpenseRecognisedDuringPeriodForBadAndDoubtfulDebtsForRelatedPartyTransactionStateEntitiesRelatedParties": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpenseRecognisedDuringPeriodForBadAndDoubtfulDebtsForRelatedPartyTransactionStateEntitiesRelatedParties",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "(Losses)/reversal with state entities - related parties"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExpenseRecognisedDuringPeriodForBadAndDoubtfulDebtsForTransactionWithPrivateSector": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpenseRecognisedDuringPeriodForBadAndDoubtfulDebtsForTransactionWithPrivateSector",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "(Losses)/reversal with the private sector/government entities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExpenseRelatingToShorttermLeasesForWhichRecognitionExemptionHasBeenUsed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ExpenseRelatingToShorttermLeasesForWhichRecognitionExemptionHasBeenUsed",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Expenses of short-term and low-value leases",
        "label": "Expense relating to short-term leases for which recognition exemption has been used"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of the expense relating to short-term leases accounted for applying paragraph 6 of IFRS 16. This expense need not include the expense relating to leases with a lease term of one month or less. Short-term lease is a lease that, at the commencement date, has a lease term of 12 months or less. A lease that contains a purchase option is not a short-term lease."
       }
      }
     },
     "auth_ref": [
      "r149"
     ]
    },
    "sbs_ExpensesByNatureAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpensesByNatureAxis",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expenses By Nature [Axis]",
        "verboseLabel": "ExpensesByNatureAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExpensesByNatureDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpensesByNatureDomain",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "auth_ref": []
    },
    "sbs_ExpensesCapitalizedInAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpensesCapitalizedInAssets",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capitalized"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExpensesToBeRecognizedByEmployer": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExpensesToBeRecognizedByEmployer",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expenditures to be recognized by the employer"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ExposureMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ExposureMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exposure [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_Extension": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "Extension",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Extension",
        "documentation": "Extension number for local phone number."
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FairValueAdjustment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FairValueAdjustment",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value adjustment"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FairValueAsDeemedCostAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FairValueAsDeemedCostAxis",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value as deemed cost [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r122"
     ]
    },
    "sbs_FairValueHedgeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FairValueHedgeMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Hedge [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FairValueOfAcquiredReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FairValueOfAcquiredReceivables",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-convertible unsecured debentures acquired"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of receivables acquired in a business combination. [Refer: Total for all business combinations [member]]"
       }
      }
     },
     "auth_ref": [
      "r169"
     ]
    },
    "sbs_FairValueOfChangesInBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FairValueOfChangesInBorrowings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FairValueOfPlansAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FairValueOfPlansAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value of the plan's assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FairValueOnGrantDate": {
     "xbrltype": "perShareItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FairValueOnGrantDate",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value on the grant date"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FederalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FederalMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Federal [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FehidroMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FehidroMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fehidro [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinanceChargesFromCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinanceChargesFromCustomers",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Charges from Customers"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinanceCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinanceCost",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Financing",
        "label": "FinanceCost"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinanceCosts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FinanceCosts",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Finance costs",
        "verboseLabel": "Financing",
        "label": "Finance costs"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of costs associated with financing activities of the entity."
       }
      }
     },
     "auth_ref": [
      "r33"
     ]
    },
    "sbs_FinanceIncomeExpenseNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinanceIncomeExpenseNet",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails",
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial result, net",
        "verboseLabel": "[custom:FinanceIncomeExpenseNet]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinanceIncomes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinanceIncomes",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:FinanceIncomes]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialAssetAdjustment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialAssetAdjustment",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 18.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Financial Asset of the concession \u2013 inflation adjustment",
        "label": "FinancialAssetAdjustment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialAssetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialAssetMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Asset [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialAssetOfConcessionRestatement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialAssetOfConcessionRestatement",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Asset of the Concession - Restatement"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FinancialAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails",
      "http://sabesp.com.br/role/RiskManagementDetails3",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial asset of the concession",
        "verboseLabel": "Assets",
        "periodStartLabel": "Financial assets at beginning",
        "periodEndLabel": "Financial assets at ending"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that are: (a) cash; (b) an equity instrument of another entity; (c) a contractual right: (i) to receive cash or another financial asset from another entity; or (ii) to exchange financial assets or financial liabilities with another entity under conditions that are potentially favourable to the entity; or (d) a contract that will, or may be, settled in the entity\u2019s own equity instruments and is: (i) a non-derivative for which the entity is, or may be, obliged to receive a variable number of the entity\u2019s own equity instruments; or (ii) a derivative that will, or may be, settled other than by the exchange of a fixed amount of cash or another financial asset for a fixed number of the entity\u2019s own equity instruments. For this purpose the entity\u2019s own equity instruments do not include puttable financial instruments classified as equity instruments in accordance with paragraphs 16A-16B of IAS 32, instruments that impose on the entity an obligation to deliver to another party a pro rata share of the net assets of the entity only on liquidation and are classified as equity instruments in accordance with paragraphs 16C-16D of IAS 32, or instruments that are contracts for the future receipt or delivery of the entity\u2019s own equity instruments. [Refer: Classes of financial instruments [domain]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r177",
      "r181",
      "r182",
      "r185",
      "r246"
     ]
    },
    "ifrs-full_FinancialAssetsAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FinancialAssetsAtFairValue",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value of asset position"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of financial assets. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r177"
     ]
    },
    "sbs_FinancialIncomeExpenseAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialIncomeExpenseAxis",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Income Expense [Axis]",
        "verboseLabel": "FinancialIncomeExpenseAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialIncomeExpenseDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialIncomeExpenseDomain",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "auth_ref": []
    },
    "sbs_FinancialIncomeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialIncomeMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Income [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialIncomeNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialIncomeNet",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_ProfitLossBeforeTax",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial income/(expenses), net"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInstitutionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInstitutionMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Institution [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInterestIncomeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInterestIncomeMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Interest Income [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInvesmentsInvestment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInvesmentsInvestment",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Financial investments - Noncurrent",
        "label": "FinancialInvesmentsInvestment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInvesmentsRedemption": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInvesmentsRedemption",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial investments - Redemption"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInvestments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInvestments",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial investments - Investment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInvestmentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInvestmentsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Investments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FinancialInvestmentsNonCurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialInvestmentsNonCurrent",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial investments, non current"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FinancialLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities that are: (a) a contractual obligation: (i) to deliver cash or another financial asset to another entity; or (ii) to exchange financial assets or financial liabilities with another entity under conditions that are potentially unfavourable to the entity; or (b) a contract that will, or may be, settled in the entity\u2019s own equity instruments and is: (i) a non-derivative for which the entity is, or may be, obliged to deliver a variable number of the entity\u2019s own equity instruments; or (ii) a derivative that will, or may be, settled other than by the exchange of a fixed amount of cash or another financial asset for a fixed number of the entity\u2019s own equity instruments. For this purpose, rights, options or warrants to acquire a fixed number of the entity\u2019s own equity instruments for a fixed amount of any currency are equity instruments if the entity offers the rights, options or warrants pro rata to all of its existing owners of the same class of its own non-derivative equity instruments. Also, for those purposes the entity\u2019s own equity instruments do not include puttable financial instruments that are classified as equity instruments in accordance with paragraphs 16A-16B of IAS 32, instruments that impose on the entity an obligation to deliver to another party a pro rata share of the net assets of the entity only on liquidation and are classified as equity instruments in accordance with paragraphs 16C-16D of IAS 32, or instruments that are contracts for the future receipt or delivery of the entity\u2019s own equity instruments. As an exception, an instrument that meets the definition of a financial liability is classified as an equity instrument if it has all the features and meets the conditions in paragraphs 16A-16B or paragraphs 16C-16D of IAS 32. [Refer: Classes of financial instruments [domain]; Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r177"
     ]
    },
    "ifrs-full_FinancialLiabilitiesAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FinancialLiabilitiesAtFairValue",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair value",
        "verboseLabel": "Fair value of liability position"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of financial liabilities. [Refer: At fair value [member]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r177"
     ]
    },
    "sbs_FinancialNetBeforeExchangeRateChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FinancialNetBeforeExchangeRateChanges",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:FinancialNetBeforeExchangeRateChanges]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FixturesAndFittingsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FixturesAndFittingsMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fixtures and fittings [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing fixtures and fittings that are not permanently attached to real property. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r225"
     ]
    },
    "sbs_ForeignCurrencyDenominatedBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ForeignCurrencyDenominatedBorrowings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total foreign currency-denominated borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ForeignCurrencyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ForeignCurrencyMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Currency [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_ForgoneRecoveryDueToDisqualificationOfTaxBenefitsAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ForgoneRecoveryDueToDisqualificationOfTaxBenefitsAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forgone Recovery due to Disqualification of Tax Benefits, Amount"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r343"
     ]
    },
    "ecd_ForgoneRecoveryDueToExpenseOfEnforcementAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ForgoneRecoveryDueToExpenseOfEnforcementAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forgone Recovery due to Expense of Enforcement, Amount"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r343"
     ]
    },
    "ecd_ForgoneRecoveryDueToViolationOfHomeCountryLawAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ForgoneRecoveryDueToViolationOfHomeCountryLawAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forgone Recovery due to Violation of Home Country Law, Amount"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r343"
     ]
    },
    "ecd_ForgoneRecoveryExplanationOfImpracticabilityTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ForgoneRecoveryExplanationOfImpracticabilityTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forgone Recovery, Explanation of Impracticability"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r343"
     ]
    },
    "ecd_ForgoneRecoveryIndName": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "ForgoneRecoveryIndName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Name",
        "label": "Forgone Recovery, Individual Name"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r343"
     ]
    },
    "sbs_FreeFloatMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FreeFloatMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Free Float [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FunctionalOrPresentationCurrencyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "FunctionalOrPresentationCurrencyMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member indicates information displayed in the functional or presentation currency. It also represents the standard value for the \u2018Currency in which information is displayed\u2019 axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r66"
     ]
    },
    "sbs_FundsRaisedFromUnsecuredDebenture": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FundsRaisedFromUnsecuredDebenture",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Funds raised from unsecured debentures"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_FundsRaisedFromUnsecuredDebentures": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "FundsRaisedFromUnsecuredDebentures",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_G0PlanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "G0PlanMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "G 0 Plan [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_G1PlanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "G1PlanMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "G 1 Plan [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GainLossOnDerivativesSwap": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainLossOnDerivativesSwap",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gain loss on derivatives swap"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GainLossOnFairValueOnHedged": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainLossOnFairValueOnHedged",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gain loss on fair value on the hedged item"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GainLossOnFairValueOnHedgedItem": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainLossOnFairValueOnHedgedItem",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Gain loss on fair value on the hedged item",
        "label": "GainLossOnFairValueOnHedgedItem"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GainLossOnRemeasurementOfNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "GainLossOnRemeasurementOfNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total gains/(losses)"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in a net defined benefit liability (asset) resulting from the remeasurement of that net defined benefit liability (asset). [Refer: Net defined benefit liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r56"
     ]
    },
    "sbs_GainsAndLossesOnFinancialInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainsAndLossesOnFinancialInstruments",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains and losses on financial instruments"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GainsLossesArisingFromSettlementsNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "GainsLossesArisingFromSettlementsNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial gains/(losses) on obligations"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in the net defined benefit liability (asset) resulting from settlements. Settlements are transactions that eliminate all further legal or constructive obligations for part or all of the benefits provided under a defined benefit plan, other than a payment of benefits to, or on behalf of, employees that is set out in the terms of the plan and included in the actuarial assumptions. [Refer: Net defined benefit liability (asset); Defined benefit plans [domain]; Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r57"
     ]
    },
    "ifrs-full_GainsLossesOnChangeInFairValueOfDerivatives": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "GainsLossesOnChangeInFairValueOfDerivatives",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated gain loss on derivatives swap"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) resulting from change in the fair value of derivatives recognised in profit or loss. [Refer: Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r381"
     ]
    },
    "ifrs-full_GainsLossesOnFinancialAssetsAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "GainsLossesOnFinancialAssetsAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Actuarial gains/(losses) recorded as other comprehensive income",
        "label": "Gains (losses) on financial assets at fair value through profit or loss"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) on financial assets at fair value through profit or loss. [Refer: Financial assets at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r172"
     ]
    },
    "sbs_GainsLossesWithDerivativeFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainsLossesWithDerivativeFinancialInstrumentsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses With Derivative Financial Instruments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GainslossesInFinancialIsntruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GainslossesInFinancialIsntruments",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains/(losses) in financial isntruments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GeneralAndSpecialCustomersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GeneralAndSpecialCustomersMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General And Special Customers [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GeneralExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GeneralExpenses",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "General expenses",
        "label": "GeneralExpenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GeneralExpensesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GeneralExpensesMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General Expenses [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GeneralSupplies": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GeneralSupplies",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General supplies"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GeneralSuppliesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GeneralSuppliesMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General Supplies [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GovernmentEntitiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GovernmentEntitiesMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Government Entities [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GrossProfit": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "GrossProfit",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Gross profit",
        "label": "Gross profit"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of revenue less cost of sales. [Refer: Cost of sales; Revenue]"
       }
      }
     },
     "auth_ref": [
      "r215"
     ]
    },
    "sbs_GrossSalesDeductions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GrossSalesDeductions",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gross sales deductions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_GuaranteeInsuranceForEscrowDepositRenewed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "GuaranteeInsuranceForEscrowDepositRenewed",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Guarantee insurance for escrow deposit renewed"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_HealthcarePlanI": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "HealthcarePlanI",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Healthcare plan (i)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_HealthcarePlanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "HealthcarePlanMember",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Healthcare Plan [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_HedgeCost": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "HedgeCost",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Hedge Cost"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_HedgeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "HedgeMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Hedge [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IBRDMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IBRDMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I B R D [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IDBInvest2020Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IDBInvest2020Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IDB Invest 2020 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IDBMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IDBMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I D B [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IDBsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IDBsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IDBs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IDBsNationalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IDBsNationalMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IDBs National [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IFC2025Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IFC2025Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I F C 2025 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IFCMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IFCMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I F C [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IFCsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IFCsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IFCs [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IFRS18Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IFRS18Member",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I F R S 18 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IFRS19Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IFRS19Member",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I F R S 19 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IPCAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IPCAMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I P C A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IPCANetExposureMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IPCANetExposureMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I P C A Net Exposure [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IPCASeriesThreeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IPCASeriesThreeMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I P C A Series Three [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IRRFWithholdingIncomeTaxOnFinancialsInvestmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IRRFWithholdingIncomeTaxOnFinancialsInvestmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "I R R F Withholding Income Tax On Financials Investments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_IcfrAuditorAttestationFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "IcfrAuditorAttestationFlag",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "ICFR Auditor Attestation Flag"
       }
      }
     },
     "auth_ref": [
      "r270",
      "r272",
      "r295"
     ]
    },
    "sbs_IfrsStatementLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IfrsStatementLineItems",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails4",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables",
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails",
      "http://sabesp.com.br/role/CommitmentsDetails",
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1",
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/EquityDetails",
      "http://sabesp.com.br/role/EquityDetails2",
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4",
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
      "http://sabesp.com.br/role/FinancialIncomeNetDetails",
      "http://sabesp.com.br/role/FinancialInstrumentsDetails",
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetails",
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/IntangibleAssetsDetails",
      "http://sabesp.com.br/role/IntangibleAssetsDetails1",
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/IntangibleAssetsDetails4",
      "http://sabesp.com.br/role/IntangibleAssetsDetails5",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative",
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative",
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails5",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6",
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7",
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1",
      "http://sabesp.com.br/role/RiskManagementDetails2",
      "http://sabesp.com.br/role/RiskManagementDetails3",
      "http://sabesp.com.br/role/RiskManagementDetails4",
      "http://sabesp.com.br/role/StatementOfChangesInEquity",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/TradeReceivablesDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails1",
      "http://sabesp.com.br/role/TradeReceivablesDetails4",
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IfrsStatementLineItems [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IfrsStatementTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IfrsStatementTable",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails",
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative",
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/RiskManagementDetails",
      "http://sabesp.com.br/role/RiskManagementDetails1",
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IfrsStatementTable [Table]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IguaSaneamentoSAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IguaSaneamentoSAMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Igua Saneamento S A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ImpactInTheIncomeStatementsOfRightOfUse": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ImpactInTheIncomeStatementsOfRightOfUse",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Decrease in profit for the period"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ImpactOnPresentValueOfDefinedBenefitObligations": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ImpactOnPresentValueOfDefinedBenefitObligations",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Impact on present value of the defined benefit obligations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncentivizedDismissalProgramPdiIii": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncentivizedDismissalProgramPdiIii",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Incentivized Dismissal Program - IDP (iii)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncomeBeforeTaxes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncomeBeforeTaxes",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income before taxes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncomeOnFinancialInvestmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncomeOnFinancialInvestmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income On Financial Investments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncomeStatementAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncomeStatementAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit or loss [abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncomeTaxAndSocialContribution": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncomeTaxAndSocialContribution",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_ProfitLoss",
       "weight": -1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedTotalLabel": "Total Income tax and social contribution",
        "label": "IncomeTaxAndSocialContribution"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncomeTaxAndSocialContribution1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncomeTaxAndSocialContribution1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Income and social contribution taxes",
        "label": "IncomeTaxAndSocialContribution1"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncomeTaxAndSocialsContributionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncomeTaxAndSocialsContributionMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax And Socials Contribution [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncomeTaxExpenseContinuingOperations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncomeTaxExpenseContinuingOperations",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current income and social contribution taxes"
       }
      },
      "en": {
       "role": {
        "documentation": "The aggregate amount included in the determination of profit (loss) for the period in respect of current tax and deferred tax. [Refer: Current tax expense (income); Deferred tax expense (income)]"
       }
      }
     },
     "auth_ref": [
      "r34",
      "r41",
      "r42",
      "r43",
      "r78",
      "r135",
      "r198"
     ]
    },
    "ifrs-full_IncomeTaxesPaidRefundClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncomeTaxesPaidRefundClassifiedAsOperatingActivities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Income tax and social contribution paid",
        "label": "Income taxes paid (refund), classified as operating activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from income taxes paid or refunded, classified as operating activities. [Refer: Income taxes paid (refund)]"
       }
      }
     },
     "auth_ref": [
      "r108",
      "r233"
     ]
    },
    "sbs_IncreaseDecreaseInAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseDecreaseInAssetsAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes in assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseInCashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseInCashAndCashEquivalents",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Increase / (decrease) in cash and cash equivalents in the year",
        "label": "Increase (decrease) in cash and cash equivalents after effect of exchange rate changes"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in cash and cash equivalents after the effect of exchange rate changes on cash and cash equivalents held in foreign currencies. [Refer: Cash and cash equivalents; Effect of exchange rate changes on cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r111"
     ]
    },
    "ifrs-full_IncreaseDecreaseInDeferredTaxLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseInDeferredTaxLiabilityAsset",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total net change"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in a deferred tax liability (asset). [Refer: Deferred tax liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r384"
     ]
    },
    "ifrs-full_IncreaseDecreaseInDefinedBenefitObligationDueToReasonablyPossibleIncreaseInActuarialAssumption": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseInDefinedBenefitObligationDueToReasonablyPossibleIncreaseInActuarialAssumption",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total gross payroll"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in a defined benefit obligation that would have been caused by an increase in a significant actuarial assumption that was reasonably possible at the end of the reporting period. [Refer: Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r60"
     ]
    },
    "sbs_IncreaseDecreaseInLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseDecreaseInLiabilitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes in liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseThroughChangeInEquityOfSubsidiaries": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseThroughChangeInEquityOfSubsidiaries",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Equity Accounting",
        "label": "Increase (decrease) through change in equity of subsidiaries, equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in the entity's equity resulting from the change in the equity of subsidiaries. [Refer: Total for all subsidiaries [member]]"
       }
      }
     },
     "auth_ref": [
      "r375"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughTimeValueOfMoneyAdjustmentOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseThroughTimeValueOfMoneyAdjustmentOtherProvisions",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest and inflation adjustment"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in other provisions through adjustments arising from the passage of time. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r91"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughTransferToStatutoryReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseThroughTransferToStatutoryReserve",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers to investment reserve"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in equity resulting from transfers to a statutory reserve. [Refer: Statutory reserve]"
       }
      }
     },
     "auth_ref": [
      "r375"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughTransfersIntangibleAssetsOtherThanGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseThroughTransfersIntangibleAssetsOtherThanGoodwill",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Transfers",
        "label": "Increase (decrease) through transfers, intangible assets other than goodwill"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in intangible assets other than goodwill resulting from transfers. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r393"
     ]
    },
    "sbs_IncreaseDecreaseThroughTransfersOfContractAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseDecreaseThroughTransfersOfContractAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfer of contract assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseThroughTransfersPropertyPlantAndEquipment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IncreaseDecreaseThroughTransfersPropertyPlantAndEquipment",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Transfers",
        "label": "Increase (decrease) through transfers, property, plant and equipment"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in property, plant and equipment resulting from transfers. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r386"
     ]
    },
    "sbs_IncreaseDecreaseThroughTransfersToFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseDecreaseThroughTransfersToFinancialAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers to financial assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncreaseOfOnePercentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseOfOnePercentMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Of One Percent [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IncreaseOfOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IncreaseOfOneYearMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Of One Year [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IndiceNacionalDePrecosAoConsumidorAmplosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IndiceNacionalDePrecosAoConsumidorAmplosMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Indice Nacional De Precos Ao Consumidor Amplos [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_IndividualAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "IndividualAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure",
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure",
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements",
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Individual [Axis]"
       }
      }
     },
     "auth_ref": [
      "r292",
      "r303",
      "r317",
      "r334",
      "r343",
      "r347",
      "r355"
     ]
    },
    "sbs_InflationAdjustmentAndExchangeGainsLossesOnBorrowingsAndFinancing": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InflationAdjustmentAndExchangeGainsLossesOnBorrowingsAndFinancing",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Inflation adjustment and exchange gains (losses) on borrowings and financing",
        "label": "InflationAdjustmentAndExchangeGainsLossesOnBorrowingsAndFinancing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InflationAdjustmentGainsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InflationAdjustmentGainsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflation Adjustment Gains [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InflationAdjustmentOnBorrowingsAndFinancingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InflationAdjustmentOnBorrowingsAndFinancingMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflation Adjustment On Borrowings And Financing [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InfranextMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InfranextMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Infranext [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InitiallyAppliedIFRSsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InitiallyAppliedIFRSsAxis",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Initially applied IFRSs [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r116"
     ]
    },
    "ifrs-full_InitiallyAppliedIFRSsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InitiallyAppliedIFRSsDomain",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for IFRSs that have been initially applied by the entity. It also represents the standard value for the 'Initially applied IFRSs' axis if no other member is used. [Refer: IFRSs [member]]"
       }
      }
     },
     "auth_ref": [
      "r116"
     ]
    },
    "ecd_InsiderTradingArrLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "InsiderTradingArrLineItems",
     "auth_ref": [
      "r353"
     ]
    },
    "ecd_InsiderTradingPoliciesProcLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "InsiderTradingPoliciesProcLineItems",
     "lang": {
      "en-us": {
       "role": {
        "label": "Insider Trading Policies and Procedures [Line Items]"
       }
      }
     },
     "auth_ref": [
      "r273",
      "r358"
     ]
    },
    "ecd_InsiderTrdPoliciesProcAdoptedFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "InsiderTrdPoliciesProcAdoptedFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingPoliciesProc"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Insider Trading Policies and Procedures Adopted"
       }
      }
     },
     "auth_ref": [
      "r273",
      "r358"
     ]
    },
    "ecd_InsiderTrdPoliciesProcNotAdoptedTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "InsiderTrdPoliciesProcNotAdoptedTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingPoliciesProc"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Insider Trading Policies and Procedures Not Adopted"
       }
      }
     },
     "auth_ref": [
      "r273",
      "r358"
     ]
    },
    "sbs_IntangibleAssetsAccumulatedAmortization": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IntangibleAssetsAccumulatedAmortization",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated amortization"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IntangibleAssetsOtherThanGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IntangibleAssetsOtherThanGoodwill",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of identifiable non-monetary assets without physical substance. This amount does not include goodwill. [Refer: Goodwill]"
       }
      }
     },
     "auth_ref": [
      "r10",
      "r96"
     ]
    },
    "sbs_IntangibleAssetsOtherThanGoodwill1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IntangibleAssetsOtherThanGoodwill1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Intangible assets, beginning",
        "periodEndLabel": "Intangible assets, ending",
        "label": "Right of use"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IntangibleAssetsOtherThanGoodwillCarryingAmountAtCostOfRevaluedAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IntangibleAssetsOtherThanGoodwillCarryingAmountAtCostOfRevaluedAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of intangible assets other than goodwill that would have been recognised had the revalued intangible assets been measured using the cost model after recognition. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r98"
     ]
    },
    "sbs_InterAmericanDevelopmentBank1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterAmericanDevelopmentBank1Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inter American Development Bank 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterAmericanDevelopmentBank2Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterAmericanDevelopmentBank2Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inter American Development Bank 2 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterAmericanDevelopmentBankIDBMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterAmericanDevelopmentBankIDBMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inter-American Development Bank (IDB) [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterAmericanDevelopmentBankMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterAmericanDevelopmentBankMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inter American Development Bank [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterAmericanInvestmentCorporationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterAmericanInvestmentCorporationMember",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inter American Investment Corporation [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestAndChargeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestAndChargeMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest And Charge [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestAndChargesForeignCurrencyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestAndChargesForeignCurrencyMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest And Charges Foreign Currency [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestAndChargesLocalCurrencyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestAndChargesLocalCurrencyMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest And Charges Local Currency [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestAndInflationAdjustmentPpp": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestAndInflationAdjustmentPpp",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest and inflation adjustment (PPP)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestAndInflationAdjustmentsNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestAndInflationAdjustmentsNet",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Interest and inflation adjustments, net",
        "label": "InterestAndInflationAdjustmentsNet"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestBenchmarkRatesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestBenchmarkRatesMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Benchmark Rates [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestCost",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Interest cost",
        "label": "InterestCost"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestCostCapitalised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestCostCapitalised",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Inflation adjustment/Exchange rate change - Capitalized",
        "label": "InterestCostCapitalised"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestCostRateEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestCostRateEmployeeBenefits",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest cost rates"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestCostsCapitalised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestCostsCapitalised",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflation adjustment/Exchange rate change - Capitalized"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest costs that an entity incurs in connection with the borrowing of funds that are directly attributable to the acquisition, construction or production of a qualifying asset and which form part of the cost of that asset."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_InterestCostsCapitalised1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestCostsCapitalised1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest capitalized in the period (Note 13 (a))"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestCostsIncurred": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestCostsIncurred",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Interest paid",
        "label": "Interest costs incurred"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest costs that an entity incurs."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_InterestExpenseIncomeNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestExpenseIncomeNetDefinedBenefitLiabilityAsset",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Interest cost",
        "label": "Increase (decrease) in net defined benefit liability (asset) resulting from interest expense (income)"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in the net defined benefit liability (asset) resulting from the passage of time. [Refer: Interest expense; Net defined benefit liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r53"
     ]
    },
    "ifrs-full_InterestExpenseOnBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestExpenseOnBorrowings",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest and charges from borrowings and financing"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest expense on borrowings. [Refer: Interest expense; Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_InterestExpenseOnCapital2": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestExpenseOnCapital2",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on capital (R$\u00a02.28 per share)"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestExpenseOnLeaseLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestExpenseOnLeaseLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Financial result \u2013 interest expense and inflation adjustment",
        "label": "Interest expense on lease liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest expense on lease liabilities. [Refer: Lease liabilities]"
       }
      }
     },
     "auth_ref": [
      "r148"
     ]
    },
    "sbs_InterestInflationAdjustmentsAndExchangeVariationsCapitalizaedInTheContractAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestInflationAdjustmentsAndExchangeVariationsCapitalizaedInTheContractAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest inflation adjustments and exchange variations contract asset"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestInflationAdjustmentsOnProvisionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestInflationAdjustmentsOnProvisionsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Inflation Adjustments On Provisions [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOfBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOfBorrowings",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest of borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnBorrowingsAndFinancing": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnBorrowingsAndFinancing",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on borrowings and financing"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnCapitalPayableMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnCapitalPayableMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest On Capital Payable [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnEquity",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on equity"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnEquityValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnEquityValue",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on equity (December 19, 2025)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnMaximumLimitOfLiabilitiesassets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnMaximumLimitOfLiabilitiesassets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on the maximum limit of liabilities/(assets)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestOnMaximumLimitOfRecognition": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestOnMaximumLimitOfRecognition",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest on the maximum limit of recognition"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestPaidClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestPaidClassifiedAsOperatingActivities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": -1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Interest Paid",
        "label": "Interest paid, classified as operating activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for interest paid, classified as operating activities."
       }
      }
     },
     "auth_ref": [
      "r107"
     ]
    },
    "sbs_InterestPublicprivatePartnership": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestPublicprivatePartnership",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Public-Private Partnership - PPP"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestRateRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InterestRateRiskMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest rate risk [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the type of risk that the fair value or future cash flows of a financial instrument will fluctuate because of changes in market interest rates. [Refer: Classes of financial instruments [domain]]"
       }
      }
     },
     "auth_ref": [
      "r158",
      "r159",
      "r160",
      "r161",
      "r194"
     ]
    },
    "sbs_InterestRateSwaps": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestRateSwaps",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest rate swaps"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestRatesDuringTheYear": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestRatesDuringTheYear",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities Interest Rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestRatesDuringTheYear1": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestRatesDuringTheYear1",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets Interest Rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestRatesSwapMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestRatesSwapMember",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Rates Swap [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestToBeIncurred1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestToBeIncurred1Member",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest To Be Incurred 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InterestToBeIncurredMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InterestToBeIncurredMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest To Be Incurred [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InternationaBankForReconstructionAndDevelopmentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InternationaBankForReconstructionAndDevelopmentMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Internationa Bank For Reconstruction And Development [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InternationalBankForReconstructionAndDevelopmenstMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InternationalBankForReconstructionAndDevelopmenstMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "International Bank for Reconstruction and Development (IBRD) [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InternationalFinanceCorporation1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InternationalFinanceCorporation1Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "International Finance Corporation 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InternationalFinanceCorporation2Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InternationalFinanceCorporation2Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "International Finance Corporation 2 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InternationalFinanceCorporationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InternationalFinanceCorporationMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "International Finance Corporation [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Inventories": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Inventories",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inventories",
        "verboseLabel": "Inventory"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current inventories. [Refer: Inventories]"
       }
      }
     },
     "auth_ref": [
      "r12",
      "r64",
      "r217"
     ]
    },
    "ifrs-full_InvestmentAccountedForUsingEquityMethod": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InvestmentAccountedForUsingEquityMethod",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investments"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of investments accounted for using the equity method. The equity method is a method of accounting whereby the investment is initially recognised at cost and adjusted thereafter for the post-acquisition change in the investor's share of net assets of the investee. The investor's profit or loss includes its share of the profit or loss of the investee. The investor's other comprehensive income includes its share of the other comprehensive income of the investee. [Refer: At cost [member]]"
       }
      }
     },
     "auth_ref": [
      "r11",
      "r136",
      "r200"
     ]
    },
    "sbs_InvestmentAccountedForUsingEquityMethod1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InvestmentAccountedForUsingEquityMethod1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Investments",
        "label": "InvestmentAccountedForUsingEquityMethod1"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InvestmentFundsAmountContributedToFairValueOfPlanAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InvestmentFundsAmountContributedToFairValueOfPlanAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total fixed income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount investment funds contribute to the fair value of defined benefit plan assets. [Refer: Plan assets, at fair value; Defined benefit plans [domain]; Investment funds [member]]"
       }
      }
     },
     "auth_ref": [
      "r228"
     ]
    },
    "ifrs-full_InvestmentIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InvestmentIncome",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of investment income, such as interest and dividends."
       }
      }
     },
     "auth_ref": [
      "r76",
      "r381"
     ]
    },
    "ifrs-full_InvestmentProperty": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "InvestmentProperty",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment properties"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of property (land or a building - or part of a building - or both) held (by the owner or by the lessee as a right-of-use asset) to earn rentals or for capital appreciation or both, rather than for: (a) use in the production or supply of goods or services or for administrative purposes; or (b) sale in the ordinary course of business."
       }
      }
     },
     "auth_ref": [
      "r9",
      "r101",
      "r103"
     ]
    },
    "sbs_InvestmentReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InvestmentReserve",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment reserve"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InvestmentReserveMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InvestmentReserveMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment Reserve [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InvestmentReserves": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InvestmentReserves",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:InvestmentReserves]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_InvestmentsAndFinancingOperationsAffectingIntangibleAssetsButNotCashAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "InvestmentsAndFinancingOperationsAffectingIntangibleAssetsButNotCashAbstract",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment and financing operations affecting intangible assets but not cash:"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_IrrfWoInterestOnEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IrrfWoInterestOnEquity",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:IrrfWoInterestOnEquity]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IssuedCapital": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IssuedCapital",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Capital stock"
       }
      },
      "en": {
       "role": {
        "documentation": "The nominal value of capital issued."
       }
      }
     },
     "auth_ref": [
      "r219"
     ]
    },
    "ifrs-full_IssuedCapitalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "IssuedCapitalMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issued capital [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing issued capital."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "sbs_IssuedRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "IssuedRate",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issued rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ItemsNotAffectingCash": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ItemsNotAffectingCash",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Items not affecting cash (see breakdown below)",
        "verboseLabel": "Total",
        "label": "ItemsNotAffectingCash"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ItemsWhichWillBeSubsequentlyReclassifiedToIncomeStatement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ItemsWhichWillBeSubsequentlyReclassifiedToIncomeStatement",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Items which will be subsequently reclassified to the income statement:"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JICA1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JICA1Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "J I C A 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JICAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JICAMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails7",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "J I C A [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JudicialBondsDiscount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JudicialBondsDiscount",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Judicial bonds discount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JudicialBondsOthers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JudicialBondsOthers",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Judicial bonds others"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JudicialBondsReceipt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JudicialBondsReceipt",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Judicial bonds receipt"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JudicialPaymentOrder": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JudicialPaymentOrder",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Judicial bonds beginning balance",
        "periodEndLabel": "Judicial bonds ending balance",
        "label": "JudicialPaymentOrder"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_JudicialPaymentReceived": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "JudicialPaymentReceived",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Judicial payment received"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_KeyManagementPersonnelCompensation": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "KeyManagementPersonnelCompensation",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total compensation"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of compensation to key management personnel. [Refer: Key management personnel of entity or parent [member]]"
       }
      }
     },
     "auth_ref": [
      "r69"
     ]
    },
    "ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "KeyManagementPersonnelCompensationSharebasedPayment",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share-based payments"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of compensation to key management personnel in the form of share-based payments. [Refer: Key management personnel of entity or parent [member]]"
       }
      }
     },
     "auth_ref": [
      "r68"
     ]
    },
    "ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "KeyManagementPersonnelCompensationShorttermEmployeeBenefits",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Short-term benefits to employees and key management personnel"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of compensation to key management personnel in the form of short-term employee benefits. [Refer: Key management personnel of entity or parent [member]]"
       }
      }
     },
     "auth_ref": [
      "r67"
     ]
    },
    "sbs_KnowledgeRetentionProgramPrc": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "KnowledgeRetentionProgramPrc",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Knowledge Retention Program (KRP)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LaborClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LaborClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Labor Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LaborObligationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LaborObligationsMember",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Labor Obligations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LandMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LandMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Land [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing land held by the entity for use in operations. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r224"
     ]
    },
    "ifrs-full_LaterThanFiveYearsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanFiveYearsMember",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than five years [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than five years."
       }
      }
     },
     "auth_ref": [
      "r153",
      "r154",
      "r163",
      "r248",
      "r252",
      "r256"
     ]
    },
    "sbs_LaterThanFourMonthAndNotLaterThanSixMonthsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LaterThanFourMonthAndNotLaterThanSixMonthsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later Than Four Month And Not Later Than Six Months [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LaterThanOneMonthAndNotLaterThanTwoMonthsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanOneMonthAndNotLaterThanTwoMonthsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than one month and not later than two months [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than one month and not later than two months."
       }
      }
     },
     "auth_ref": [
      "r246",
      "r255",
      "r377"
     ]
    },
    "ifrs-full_LaterThanOneYearAndNotLaterThanThreeYearsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanOneYearAndNotLaterThanThreeYearsMember",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than one year and not later than three years [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than one year and not later than three years."
       }
      }
     },
     "auth_ref": [
      "r248",
      "r251",
      "r256"
     ]
    },
    "ifrs-full_LaterThanOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanOneYearMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than one year [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than one year."
       }
      }
     },
     "auth_ref": [
      "r21"
     ]
    },
    "ifrs-full_LaterThanSixMonthsAndNotLaterThanOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanSixMonthsAndNotLaterThanOneYearMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than six months and not later than one year [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than six months and not later than one year."
       }
      }
     },
     "auth_ref": [
      "r248",
      "r250",
      "r256"
     ]
    },
    "ifrs-full_LaterThanThreeMonthsAndNotLaterThanFourMonthsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanThreeMonthsAndNotLaterThanFourMonthsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than three months and not later than four months [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than three months and not later than four months."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_LaterThanThreeYearAndNotLaterThanFiveYearsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LaterThanThreeYearAndNotLaterThanFiveYearsMember",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later Than Three Year And Not Later Than Five Years [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LaterThanTwoMonthsAndNotLaterThanThreeMonthsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LaterThanTwoMonthsAndNotLaterThanThreeMonthsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later than two months and not later than three months [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than two months and not later than three months."
       }
      }
     },
     "auth_ref": [
      "r246",
      "r255",
      "r377"
     ]
    },
    "sbs_Leases1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Leases1Member",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesConcessionAgreementsProgramContractsAndContractAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesConcessionAgreementsProgramContractsAndContractAssetsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases (Concession Agreements, Program Contracts and Contract Assets) [member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesConcessionAndProgramContractsCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesConcessionAndProgramContractsCost",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total Leases and Right of use"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesConcessionAndProgramContractsNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesConcessionAndProgramContractsNet",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total Leases and Right of use",
        "label": "LeasesConcessionAndProgramContractsNet"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesOthersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesOthersMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases (Others) [member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesRelatedToConcessionAgreementsAndProgramContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesRelatedToConcessionAgreementsAndProgramContractsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases Related To Concession Agreements And Program Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeasesRelatedToConcessionAgreementsURAE1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeasesRelatedToConcessionAgreementsURAE1Member",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leases - Concession Agreement \u0096 URAE-1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LegalEntityOneAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LegalEntityOneAxis",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Legal Entity One [Axis]",
        "verboseLabel": "LegalEntityOneAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LegalEntityOneDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LegalEntityOneDomain",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "auth_ref": []
    },
    "sbs_LegalReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LegalReserve",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Legal reserve",
        "label": "LegalReserve"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeveragePercentage": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeveragePercentage",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Leverage percentage"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LeverageRatio": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LeverageRatio",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "LeverageRatio"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Liabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Liabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_EquityAndLiabilities",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total liabilities",
        "verboseLabel": "Liabilities",
        "label": "Liabilities [Default Label]"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of a present obligation of the entity to transfer an economic resource as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": [
      "r18",
      "r137",
      "r138",
      "r139",
      "r199",
      "r204"
     ]
    },
    "ifrs-full_LiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LiabilitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LiabilitiesArisingFromFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LiabilitiesArisingFromFinancingActivities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financing amount"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities for which cash flows were, or future cash flows will be, classified in the statement of cash flows as cash flows from financing activities. [Refer: Cash flows from (used in) financing activities; Liabilities]"
       }
      }
     },
     "auth_ref": [
      "r237"
     ]
    },
    "sbs_LiabilityAsPerStatementOfFinancialPositionPensionObligations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LiabilityAsPerStatementOfFinancialPositionPensionObligations",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total pension plan obligations (deficit)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LifeExpectationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LifeExpectationMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Life Expectation [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LocalCurrencyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LocalCurrencyMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Local Currency [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_LocalPhoneNumber": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "LocalPhoneNumber",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Local Phone Number",
        "documentation": "Local phone number for entity."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LongtermBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LongtermBorrowings",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Borrowings and financing",
        "terseLabel": "Noncurrent",
        "label": "Non-current portion of non-current borrowings"
       }
      },
      "en": {
       "role": {
        "documentation": "The non-current portion of non-current borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_LongtermDeposits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "LongtermDeposits",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Escrow Deposits"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of long-term deposits held by the entity."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_LongtermIncentivePlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LongtermIncentivePlan",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Long-Term Incentive Plan"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_LossHedgeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "LossHedgeMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loss Hedge [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MajorComponentsOfTaxExpenseIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "MajorComponentsOfTaxExpenseIncomeAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income and social contribution taxes"
       }
      }
     },
     "auth_ref": []
    },
    "cyd_MaterialCybersecurityIncidentAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident [Abstract]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r307"
     ]
    },
    "cyd_MaterialCybersecurityIncidentInformationNotAvailableOrUndeterminedTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentInformationNotAvailableOrUndeterminedTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/MaterialCybersecurityIncidentDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident Information Not Available or Undetermined [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r308"
     ]
    },
    "cyd_MaterialCybersecurityIncidentMaterialImpactOrReasonablyLikelyMaterialImpactTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentMaterialImpactOrReasonablyLikelyMaterialImpactTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/MaterialCybersecurityIncidentDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident Material Impact or Reasonably Likely Material Impact [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r309"
     ]
    },
    "cyd_MaterialCybersecurityIncidentNatureTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentNatureTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/MaterialCybersecurityIncidentDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident Nature [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r309"
     ]
    },
    "cyd_MaterialCybersecurityIncidentScopeTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentScopeTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/MaterialCybersecurityIncidentDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident Scope [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r309"
     ]
    },
    "cyd_MaterialCybersecurityIncidentTimingTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/cyd/2024",
     "localname": "MaterialCybersecurityIncidentTimingTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/cyd/role/MaterialCybersecurityIncidentDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Cybersecurity Incident Timing [Text Block]"
       }
      }
     },
     "auth_ref": [
      "r306",
      "r309"
     ]
    },
    "sbs_Maturity2031Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Maturity2031Member",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maturity 2031 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_Maturity2036Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Maturity2036Member",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maturity 2036 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MaturityAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "MaturityAxis",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails",
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maturity [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r22",
      "r145",
      "r153",
      "r154",
      "r155",
      "r156",
      "r157",
      "r163",
      "r174",
      "r187",
      "r230",
      "r248"
     ]
    },
    "ifrs-full_MaturityDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "MaturityDomain",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails",
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for aggregated time bands. It also represents the standard value for the 'Maturity' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r22",
      "r145",
      "r153",
      "r154",
      "r155",
      "r156",
      "r157",
      "r163",
      "r174",
      "r230",
      "r248",
      "r253"
     ]
    },
    "ifrs-full_MaximumExposureToCreditRisk": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "MaximumExposureToCreditRisk",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total exposure",
        "label": "Maximum exposure to credit risk"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount that best represents the maximum exposure to credit risk without taking into account any collateral held or other credit enhancements (for example, netting agreements that do not qualify for offset in accordance with IAS 32). [Refer: Credit risk [member]]"
       }
      }
     },
     "auth_ref": [
      "r183"
     ]
    },
    "sbs_MaximumExposureToCreditRisks": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MaximumExposureToCreditRisks",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Exposure interest rate risk",
        "label": "Exposure interest rate risk"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MaximumExposureToExchangeRisk": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MaximumExposureToExchangeRisk",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total exposure"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_MeasureAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "MeasureAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Measure [Axis]"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "ecd_MeasureName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "MeasureName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Name"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "sbs_MinimumMandatoryDividend": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MinimumMandatoryDividend",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:MinimumMandatoryDividend]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MiscellaneousOtherOperatingExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MiscellaneousOtherOperatingExpenses",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Other operating expenses",
        "label": "MiscellaneousOtherOperatingExpenses"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MiscellaneousOtherOperatingIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "MiscellaneousOtherOperatingIncome",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other operating income, net1"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of miscellaneous other operating income. [Refer: Other operating income (expense)]"
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ecd_MnpiDiscTimedForCompValFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "MnpiDiscTimedForCompValFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "MNPI Disclosure Timed for Compensation Value"
       }
      }
     },
     "auth_ref": [
      "r346"
     ]
    },
    "sbs_MogiDasCruzesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MogiDasCruzesMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Mogi Das Cruzes [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MonthlyFlowPaymentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MonthlyFlowPaymentsMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Monthly Flow Payments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_MtrlTermsOfTrdArrTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "MtrlTermsOfTrdArrTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Material Terms of Trading Arrangement"
       }
      }
     },
     "auth_ref": [
      "r354"
     ]
    },
    "sbs_MunicipalMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MunicipalMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municipal [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MunicipalityOfAgudosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MunicipalityOfAgudosMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municipality Of Agudos [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MunicipalityOfFerrazdeVasconcelosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MunicipalityOfFerrazdeVasconcelosMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municipality Of Ferrazde Vasconcelos [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MunicipalityOfSaoPauloMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MunicipalityOfSaoPauloMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municipality Of Sao Paulo [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_MunicpalityofCachoeiraPaulistaMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "MunicpalityofCachoeiraPaulistaMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municpalityof Cachoeira Paulista [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_NamedExecutiveOfficersFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NamedExecutiveOfficersFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Named Executive Officers, Footnote"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "sbs_NetActuarialLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NetActuarialLiability",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net actuarial liability"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NetDebtAdjustedEBITDAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NetDebtAdjustedEBITDAMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Debt / Adjusted EBITDA [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NetDeferredTaxLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NetDeferredTaxLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred PIS/Cofins taxes, non current liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of deferred tax liabilities net of deferred tax assets, when the absolute amount of deferred tax liabilities is greater than the absolute amount of deferred tax assets. [Refer: Deferred tax assets; Deferred tax liabilities]"
       }
      }
     },
     "auth_ref": [
      "r383"
     ]
    },
    "sbs_NetForeignExchangeGains": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NetForeignExchangeGains",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "[custom:NetForeignExchangeGains]"
       }
      }
     },
     "auth_ref": []
    },
    "us-gaap_NetIncomeLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://fasb.org/us-gaap/2024",
     "localname": "NetIncomeLoss",
     "crdr": "credit",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Income (Loss)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NetProfitabilityOnFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NetProfitabilityOnFinancialAssets",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net profitability on financial assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NetRevenue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NetRevenue",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net revenue"
       }
      }
     },
     "auth_ref": []
    },
    "dei_NoTradingSymbolFlag": {
     "xbrltype": "trueItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "NoTradingSymbolFlag",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "No Trading Symbol Flag",
        "documentation": "Boolean flag that is true only for a security having no trading symbol."
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NonAdjustingEventMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NonAdjustingEventMember",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non Adjusting Event [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_NonGaapMeasureDescriptionTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NonGaapMeasureDescriptionTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-GAAP Measure Description"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "ecd_NonPeoNeoAvgCompActuallyPaidAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NonPeoNeoAvgCompActuallyPaidAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-PEO NEO Average Compensation Actually Paid Amount"
       }
      }
     },
     "auth_ref": [
      "r324"
     ]
    },
    "ecd_NonPeoNeoAvgTotalCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NonPeoNeoAvgTotalCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-PEO NEO Average Total Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r323"
     ]
    },
    "ecd_NonRule10b51ArrAdoptedFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NonRule10b51ArrAdoptedFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-Rule 10b5-1 Arrangement Adopted"
       }
      }
     },
     "auth_ref": [
      "r354"
     ]
    },
    "ecd_NonRule10b51ArrTrmntdFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "NonRule10b51ArrTrmntdFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-Rule 10b5-1 Arrangement Terminated"
       }
      }
     },
     "auth_ref": [
      "r354"
     ]
    },
    "ifrs-full_NonadjustingEventsAfterReportingPeriodAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NonadjustingEventsAfterReportingPeriodAxis",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-adjusting events after reporting period [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r39"
     ]
    },
    "ifrs-full_NonadjustingEventsAfterReportingPeriodDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NonadjustingEventsAfterReportingPeriodDomain",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/TradeReceivablesDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for events that occur between the end of the reporting period and the date when the financial statements are authorised for issue and are indicative of conditions that arose after the reporting period. It also represents the standard value for the 'Non-adjusting events after reporting period' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r39"
     ]
    },
    "ifrs-full_NoncurrentAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total non-current assets",
        "label": "Non-current assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that do not meet the definition of current assets. [Refer: Current assets]"
       }
      }
     },
     "auth_ref": [
      "r23",
      "r128",
      "r239"
     ]
    },
    "ifrs-full_NoncurrentAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentAssetsAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-Current Assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NoncurrentContractAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentContractAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contract assets and other concession assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current contract assets. [Refer: Contract assets]"
       }
      }
     },
     "auth_ref": [
      "r141"
     ]
    },
    "ifrs-full_NoncurrentFinancialAssetsAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentFinancialAssetsAtAmortisedCost",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Financial investments",
        "label": "Non-current financial assets at amortised cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current financial assets measured at amortised cost. [Refer: Financial assets at amortised cost]"
       }
      }
     },
     "auth_ref": [
      "r191"
     ]
    },
    "ifrs-full_NoncurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total non-current liabilities",
        "label": "Non-current liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities that do not meet the definition of current liabilities. [Refer: Current liabilities]"
       }
      }
     },
     "auth_ref": [
      "r24",
      "r130",
      "r239"
     ]
    },
    "ifrs-full_NoncurrentLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentLiabilitiesAbstract",
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-Current Liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NoncurrentProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NoncurrentProvisionMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noncurrent Provision [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NoncurrentProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentProvisions",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions",
        "label": "Non-current provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current provisions, including provisions for employee benefits. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r15"
     ]
    },
    "ifrs-full_NoncurrentReceivablesDueFromRelatedParties": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentReceivablesDueFromRelatedParties",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accounts receivable, noncurrent"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current receivables due from related parties. [Refer: Total for all related parties [member]]"
       }
      }
     },
     "auth_ref": [
      "r218"
     ]
    },
    "ifrs-full_NoncurrentTradeReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NoncurrentTradeReceivables",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition",
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade receivables",
        "label": "Noncurrent"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current trade receivables. [Refer: Trade receivables]"
       }
      }
     },
     "auth_ref": [
      "r218"
     ]
    },
    "sbs_NonoperatingAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NonoperatingAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-operating assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NotLaterThanOneMonthMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NotLaterThanOneMonthMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Not later than one month [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of not later than one month."
       }
      }
     },
     "auth_ref": [
      "r247",
      "r249",
      "r256"
     ]
    },
    "ifrs-full_NotLaterThanOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NotLaterThanOneYearMember",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Not later than one year [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of not later than one year."
       }
      }
     },
     "auth_ref": [
      "r20",
      "r153",
      "r154",
      "r163",
      "r248",
      "r256"
     ]
    },
    "ifrs-full_NotesAndDebenturesIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NotesAndDebenturesIssued",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-convertible unsecured debentures",
        "verboseLabel": "Debentures issued"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of notes and debentures issued by the entity."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_NotesAndOtherExplanatoryInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NotesAndOtherExplanatoryInformationAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Notes and other explanatory information [abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NotionalAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NotionalAmount",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails2",
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Notional value"
       }
      },
      "en": {
       "role": {
        "documentation": "The nominal or face amount of a financial instrument, used to calculate payments made on that instrument."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_NumberOfParticipantsOfDefinedContributionPlan": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfParticipantsOfDefinedContributionPlan",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of participants"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NumberOfParticipantsOfRetirementBenefitPlanNotReceivingBenefits": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfParticipantsOfRetirementBenefitPlanNotReceivingBenefits",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Number of participants of retirement benefit plan not receiving benefits",
        "label": "NumberOfParticipantsOfRetirementBenefitPlanNotReceivingBenefits"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NumberOfParticipantsOfRetirementBenefitPlanReceivingBenefits": {
     "xbrltype": "decimalItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NumberOfParticipantsOfRetirementBenefitPlanReceivingBenefits",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of participants of retirement benefit plan receiving benefits"
       }
      },
      "en": {
       "role": {
        "documentation": "The number of participants in a retirement benefit plan receiving benefits."
       }
      }
     },
     "auth_ref": [
      "r79"
     ]
    },
    "sbs_NumberOfParticipantsOfRetirementBenefitPlanReceivingBenefits1": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfParticipantsOfRetirementBenefitPlanReceivingBenefits1",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of participants of retirement benefit plan not receiving benefits"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NumberOfShareIssued": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfShareIssued",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Weighted average number of ordinary shares adjusted for the effect of dilution"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NumberOfSharesGranted": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfSharesGranted",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of shares granted"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NumberOfSharesIssued": {
     "xbrltype": "sharesItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "NumberOfSharesIssued",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Number of shares issued, beginning",
        "periodEndLabel": "Number of shares issued, ending",
        "label": "Number of shares issued"
       }
      },
      "en": {
       "role": {
        "documentation": "The number of shares issued by the entity."
       }
      }
     },
     "auth_ref": [
      "r375"
     ]
    },
    "sbs_NumberOfSharesIssuedCapital": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfSharesIssuedCapital",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of shares, capital"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NumberOfSharesIssuedCommon": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfSharesIssuedCommon",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of shares, common"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_NumberOfSharesIssuedPreferenciais": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "NumberOfSharesIssuedPreferenciais",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Number of shares, preferenciais"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OciGainLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OciGainLoss",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "OCI gain loss"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OfficeEquipmentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OfficeEquipmentMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Office equipment [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing equipment used to support office functions, not specifically used in the production process. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r226"
     ]
    },
    "sbs_OperatingIncomeBeforeOtherOperatingExpensesNetAndEquityAccounting": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OperatingIncomeBeforeOtherOperatingExpensesNetAndEquityAccounting",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income from operations before other operating expenses, net and equity accounting"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OperatingRevenueFAUSP": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OperatingRevenueFAUSP",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "FAUSP (a)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OperatingRevenueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OperatingRevenueMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating Revenue [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OperatingRevenuePISAndCofins": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OperatingRevenuePISAndCofins",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "PIS and Cofins"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherAdjustmentsToReconcileProfitLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherAdjustmentsToReconcileProfitLoss",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 19.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other adjustments"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments to reconcile profit (loss) to net cash flow from (used in) operating activities that the entity does not separately disclose in the same statement or note. [Refer: Adjustments to reconcile profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r106"
     ]
    },
    "sbs_OtherAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total additions"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reimbursement amount other assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_OtherAssetsAmountContributedToFairValueOfPlanAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherAssetsAmountContributedToFairValueOfPlanAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount other types of assets not separately disclosed contribute to the fair value of defined benefit plan assets. [Refer: Plan assets, at fair value; Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r388"
     ]
    },
    "sbs_OtherBorrowingsAndFinancingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherBorrowingsAndFinancingMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails9"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Borrowings And Financing [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherBorrowingsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherBorrowingsMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails1",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Borrowings [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherCashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherCashAndCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Cash equivalents",
        "label": "Other cash and cash equivalents"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash and cash equivalents that the entity does not separately disclose in the same statement or note. [Refer: Cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r401"
     ]
    },
    "sbs_OtherCivilClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherCivilClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Civil Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherComprehensiveIncomeBeforeTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherComprehensiveIncomeBeforeTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Valuation adjustments to equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, before tax, related to gains (losses) on remeasurements of defined benefit plans, which comprise actuarial gains and losses; the return on plan assets, excluding amounts included in net interest on the net defined benefit liability (asset); and any change in the effect of the asset ceiling, excluding amounts included in net interest on the net defined benefit liability (asset). [Refer: Other comprehensive income; Defined benefit plans [domain]; Plan assets [member]; Net defined benefit liability (asset)] [Contrast: Decrease (increase) in net defined benefit liability (asset) resulting from gain (loss) on remeasurement in other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r25",
      "r35",
      "r387"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeThatWillNotBeReclassifiedToProfitOrLossNetOfTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherComprehensiveIncomeThatWillNotBeReclassifiedToProfitOrLossNetOfTax",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Actuarial gains and (losses)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income that will not be reclassified to profit or loss, net of tax. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r220",
      "r221"
     ]
    },
    "ifrs-full_OtherCurrentAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherCurrentAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current assets that the entity does not separately disclose in the same statement or note. [Refer: Current assets]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_OtherCurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherCurrentLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other liabilities",
        "verboseLabel": "Current liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current liabilities that the entity does not separately disclose in the same statement or note. [Refer: Current liabilities]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_OtherExchangeRateChangesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherExchangeRateChangesMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Exchange Rate Changes [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherExpenseByNature": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherExpenseByNature",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expenses that the entity does not separately disclose in the same statement or note when the entity uses the 'nature of expense' form for its analysis of expenses. [Refer: Expenses, by nature]"
       }
      }
     },
     "auth_ref": [
      "r38",
      "r214"
     ]
    },
    "sbs_OtherFederalTaxesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherFederalTaxesMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Federal Taxes [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherFinancialExpensesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherFinancialExpensesMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Expenses [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherFinancialIncomeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherFinancialIncomeMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Income [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherInflationAdjustmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherInflationAdjustmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Inflation Adjustments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherIntangibleAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherIntangibleAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intangible assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of intangible assets that the entity does not separately disclose in the same statement or note. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r394"
     ]
    },
    "sbs_OtherInvestmentAccountedForUsingEquityMethod1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherInvestmentAccountedForUsingEquityMethod1",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other investments"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_OtherMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherNoncurrentAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherNoncurrentAssets",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other assets",
        "label": "Other non-current assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current assets that the entity does not separately disclose in the same statement or note. [Refer: Non-current assets]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_OtherNoncurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherNoncurrentLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other liabilities",
        "terseLabel": "Noncurrent liabilities",
        "label": "Other non-current liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current liabilities that the entity does not separately disclose in the same statement or note. [Refer: Non-current liabilities]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_OtherObligationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherObligationsMember",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Obligations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherOnerousDebtAdjustedEBITDAMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherOnerousDebtAdjustedEBITDAMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Onerous Debt / Adjusted EBITDA [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherOperatingIncomeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherOperatingIncomeExpense",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other operating income (expenses), net",
        "verboseLabel": "Other operating income/(expenses), net"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of operating income (expense) that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r381"
     ]
    },
    "ecd_OtherPerfMeasureAmt": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "OtherPerfMeasureAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Performance Measure, Amount"
       }
      }
     },
     "auth_ref": [
      "r326"
     ]
    },
    "ifrs-full_OtherPropertyPlantAndEquipmentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherPropertyPlantAndEquipmentMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other property, plant and equipment [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing property, plant and equipment that the entity does not separately disclose in the same statement or note. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r385"
     ]
    },
    "ifrs-full_OtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherProvisions",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Escrow deposits",
        "label": "Other provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of provisions other than provisions for employee benefits. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r26",
      "r90"
     ]
    },
    "dei_OtherReportingStandardItemNumber": {
     "xbrltype": "otherReportingStandardItemNumberItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "OtherReportingStandardItemNumber",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Reporting Standard Item Number",
        "documentation": "\"Item 17\" or \"Item 18\" specified when the basis of accounting is neither US GAAP nor IFRS."
       }
      }
     },
     "auth_ref": [
      "r272"
     ]
    },
    "ifrs-full_OtherReserves": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherReserves",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings reserves",
        "verboseLabel": "Other reserve"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing reserves within equity, not including retained earnings. [Refer: Retained earnings]"
       }
      }
     },
     "auth_ref": [
      "r219"
     ]
    },
    "ifrs-full_OtherShorttermEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherShorttermEmployeeBenefits",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense from employee benefits (other than termination benefits), which are expected to be settled wholly within twelve months after the end of the annual reporting period in which the employees render the related services, that the entity does not separately disclose in the same statement or note. [Refer: Employee benefits expense]"
       }
      }
     },
     "auth_ref": [
      "r392"
     ]
    },
    "sbs_OtherShorttermEmployeeBenefitsFiveYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherShorttermEmployeeBenefitsFiveYear",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected in 2029 or after"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherShorttermEmployeeBenefitsFourYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherShorttermEmployeeBenefitsFourYear",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected in 2028"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherShorttermEmployeeBenefitsOneYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherShorttermEmployeeBenefitsOneYear",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected in 2025"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherShorttermEmployeeBenefitsThreeYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherShorttermEmployeeBenefitsThreeYear",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected in 2027"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherShorttermEmployeeBenefitsTwoYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherShorttermEmployeeBenefitsTwoYear",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of benefits expected in 2026"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherShorttermProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "OtherShorttermProvisions",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4",
      "http://sabesp.com.br/role/ServicesPayableDetails",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Services payable",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current provisions other than provisions for employee benefits. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r26"
     ]
    },
    "sbs_OtherTaxDifferences": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherTaxDifferences",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other differences"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OtherTaxPayablesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OtherTaxPayablesMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Tax Payables [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_Others": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Others",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Others"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OthersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OthersMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other [member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_OutsideServicesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OutsideServicesMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Outside Services [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_OutstandingAggtErrCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "OutstandingAggtErrCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Outstanding Aggregate Erroneous Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r290",
      "r301",
      "r315",
      "r341"
     ]
    },
    "ecd_OutstandingRecoveryCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "OutstandingRecoveryCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r293",
      "r304",
      "r318",
      "r344"
     ]
    },
    "ecd_OutstandingRecoveryIndName": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "OutstandingRecoveryIndName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Name",
        "label": "Outstanding Recovery, Individual Name"
       }
      }
     },
     "auth_ref": [
      "r293",
      "r304",
      "r318",
      "r344"
     ]
    },
    "sbs_OverallTotal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "OverallTotal",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Overall total"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PISAndCofinsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PISAndCofinsMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
      "http://sabesp.com.br/role/FinancialIncomeNetDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "P I S And Cofins [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PISCofinsEstimatedRevenueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PISCofinsEstimatedRevenueMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "P I S Cofins Estimated Revenue [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PISCofinsFinancialAssetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PISCofinsFinancialAssetMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "P I S Cofins Financial Asset [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PVAAccountsReceivableMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PVAAccountsReceivableMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "P V A Accounts Receivable [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ParValuePerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ParValuePerShare",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Par value"
       }
      },
      "en": {
       "role": {
        "documentation": "The nominal value per share."
       }
      }
     },
     "auth_ref": [
      "r28"
     ]
    },
    "sbs_PartialAmortizationAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PartialAmortizationAmount",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Partial amortization amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PartialInterestAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PartialInterestAmount",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Partial interest amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PartialPrincipalAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PartialPrincipalAmount",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Partial principal amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PasepForFinancialRevenuesRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PasepForFinancialRevenuesRate",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pasep for financial revenues rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PastDueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PastDueMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Past Due [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PastDueStatusAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PastDueStatusAxis",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Past due status [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "ifrs-full_PastDueStatusDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PastDueStatusDomain",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all past-due statuses. It also represents the standard value for the 'Past due status' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "sbs_PaulistaGeradoraDeEnergia1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaulistaGeradoraDeEnergia1Member",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Paulista Geradora De Energia 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PaulistaGeradoraDeEnergiaMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaulistaGeradoraDeEnergiaMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Paulista Geradora De Energia [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_PayVsPerformanceDisclosureLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PayVsPerformanceDisclosureLineItems",
     "auth_ref": [
      "r322"
     ]
    },
    "sbs_PaymentForAmortization": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaymentForAmortization",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Amortization",
        "label": "PaymentForAmortization"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PaymentFromPlanNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaymentFromPlanNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Benefits paid",
        "label": "PaymentFromPlanNetDefinedBenefitLiabilityAsset"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PaymentReceivedFromReimbursementMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaymentReceivedFromReimbursementMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment Received From Reimbursement [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PaymentsFromChangesInOwnershipInterestsInSubsidiaries": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PaymentsFromChangesInOwnershipInterestsInSubsidiaries",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payment of interest on equity, as remuneration to shareholders, in the gross amount"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for changes in ownership interests in subsidiaries that do not result in a loss of control. [Refer: Total for all subsidiaries [member]]"
       }
      }
     },
     "auth_ref": [
      "r109",
      "r110"
     ]
    },
    "ifrs-full_PaymentsFromPlanNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PaymentsFromPlanNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Benefits paid"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in the net defined benefit liability (asset) resulting from payments from the plan. [Refer: Net defined benefit liability (asset)]"
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Public-Private Partnership - PPP",
        "label": "Payments of lease liabilities, classified as financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for payment of lease liabilities, classified as financing activities. [Refer: Lease liabilities]"
       }
      }
     },
     "auth_ref": [
      "r235"
     ]
    },
    "sbs_PaymentsReceivedRelatedPartiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaymentsReceivedRelatedPartiesMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payments Received Related Parties [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PaymentsToAcquireInterestsInSubsidiariesAndAffiliates": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PaymentsToAcquireInterestsInSubsidiariesAndAffiliates",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Capital increase in investees",
        "label": "PaymentsToAcquireInterestsInSubsidiariesAndAffiliates"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_PeerGroupIssuersFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PeerGroupIssuersFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Peer Group Issuers, Footnote"
       }
      }
     },
     "auth_ref": [
      "r325"
     ]
    },
    "ecd_PeerGroupTotalShareholderRtnAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PeerGroupTotalShareholderRtnAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Peer Group Total Shareholder Return Amount"
       }
      }
     },
     "auth_ref": [
      "r325"
     ]
    },
    "sbs_PensionObligations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionObligations",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension plan obligations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PensionObligationsG1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionObligationsG1Member",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension Obligations G 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PensionObligationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionObligationsMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension Obligations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PensionPlanObligationOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionPlanObligationOther",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Other",
        "label": "PensionPlanObligationOther"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PensionPlanObligationSubtotal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionPlanObligationSubtotal",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Subtotal",
        "label": "PensionPlanObligationSubtotal"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PensionPlanObligations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PensionPlanObligations",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension plan obligations (Note 29)"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_PeoActuallyPaidCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PeoActuallyPaidCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "PEO Actually Paid Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r324"
     ]
    },
    "ecd_PeoName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PeoName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "PEO Name"
       }
      }
     },
     "auth_ref": [
      "r327"
     ]
    },
    "ecd_PeoTotalCompAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PeoTotalCompAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "PEO Total Compensation Amount"
       }
      }
     },
     "auth_ref": [
      "r323"
     ]
    },
    "ifrs-full_PercentageOfEntitysRevenue": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PercentageOfEntitysRevenue",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue"
       }
      },
      "en": {
       "role": {
        "documentation": "The percentage of the entity's revenue. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r404"
     ]
    },
    "sbs_PercentageOfFairValueOfPlansAssets": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfFairValueOfPlansAssets",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of fair value of the plan's assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PercentageOfOther": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfOther",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of other"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PercentageOfReasonablyPossibleIncreaseInActuarialAssumption": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PercentageOfReasonablyPossibleIncreaseInActuarialAssumption",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contributed percentage on average of gross payroll"
       }
      },
      "en": {
       "role": {
        "documentation": "The reasonably possible percentage of the increase in the actuarial assumption used to determine the present value of defined benefit obligation. [Refer: Actuarial assumptions [domain]]"
       }
      }
     },
     "auth_ref": [
      "r60"
     ]
    },
    "sbs_PercentageOfTotalEquities": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfTotalEquities",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of total equities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PercentageOfTotalFixedIncome": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfTotalFixedIncome",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of total fixed income"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PercentageOfTotalStructuredInvestments": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfTotalStructuredInvestments",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of total structured investments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PercentageOfTradeReceivables": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfTradeReceivables",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trade receivables, percentage"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PercentageOfVotingEquityInterestAcquired": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PercentageOfVotingEquityInterestAcquired",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquisition of common shares equivalent"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PercentageOfVotingEquityInterestsAcquired": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PercentageOfVotingEquityInterestsAcquired",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Acquired percentage",
        "verboseLabel": "Equity interest percentage",
        "terseLabel": "Acquisition of common shares equivalent"
       }
      },
      "en": {
       "role": {
        "documentation": "The percentage of voting equity interests acquired in a business combination. [Refer: Total for all business combinations [member]]"
       }
      }
     },
     "auth_ref": [
      "r167"
     ]
    },
    "sbs_PerformanceAgreements": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreements",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance agreements"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsContractAssetsAndOtherConcessionAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsContractAssetsAndOtherConcessionAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Contract assets and other concession assets",
        "label": "PerformanceAgreementsContractAssetsAndOtherConcessionAssets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsCurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsCurrent",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance Agreements"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsCurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsCurrentLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsIntangibleAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsIntangibleAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Intangible assets",
        "label": "PerformanceAgreementsIntangibleAssets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance Agreements [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsNonCurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsNonCurrent",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Performance Agreements",
        "label": "PerformanceAgreementsNonCurrent"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsNoncurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsNoncurrentLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Noncurrent liabilities",
        "label": "PerformanceAgreementsNoncurrentLiabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsTotalAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsTotalAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails7"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "PerformanceAgreementsTotalAssets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceAgreementsTotalLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceAgreementsTotalLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total liabilities",
        "label": "PerformanceAgreementsTotalLiabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PerformanceObligationsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PerformanceObligationsAxis",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance obligations [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r144"
     ]
    },
    "ifrs-full_PerformanceObligationsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PerformanceObligationsDomain",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all performance obligations. A performance obligation is a promise in a contract with a customer to transfer to the customer either: (a) a good or service (or a bundle of goods or services) that is distinct; or (b) a series of distinct goods or services that are substantially the same and that have the same pattern of transfer to the customer. This member also represents the standard value for the 'Performance obligations' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r144"
     ]
    },
    "sbs_PerformanceShare1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceShare1Member",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance Share 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PerformanceShareMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PerformanceShareMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Performance Share [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PermanentDifferencesAgreementWithAaps": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PermanentDifferencesAgreementWithAaps",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Agreement with AAPS"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PermanentDifferencesDonations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PermanentDifferencesDonations",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Donations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PermanentDifferencesProvisionLaw": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PermanentDifferencesProvisionLaw",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision Law No. 4.819/1958 \u2013 G0"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PermanentDifferencesTaxIncentives": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PermanentDifferencesTaxIncentives",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax Incentives"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PisAndCofinsRecoverableMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PisAndCofinsRecoverableMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pis And Cofins Recoverable [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PlanAssetsAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PlanAssetsAtFairValue",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Fair value of the plan's assets, beginning",
        "periodEndLabel": "Fair value of the plan's assets, ending",
        "label": "Plan assets, at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of defined benefit plan assets. Plan assets comprise assets held by a long-term employee benefit fund and qualifying insurance policies. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r391"
     ]
    },
    "sbs_PlanAssetsAtFairValues": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PlanAssetsAtFairValues",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Fair value of the plan's assets",
        "label": "PlanAssetsAtFairValues"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_PnsnBnftsAdjFnTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PnsnBnftsAdjFnTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension Benefits Adjustments, Footnote"
       }
      }
     },
     "auth_ref": [
      "r324"
     ]
    },
    "ifrs-full_PostemploymentBenefitExpenseDefinedBenefitPlans": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PostemploymentBenefitExpenseDefinedBenefitPlans",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 16.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Pension plan obligations",
        "label": "Post-employment benefit expense in profit or loss, defined benefit plans"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of post-employment benefit expense included in profit or loss relating to defined benefit plans. [Refer: Profit (loss); Defined benefit plans [domain]] [Contrast: Increase (decrease) in net defined benefit liability (asset) resulting from expense (income) in profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r387",
      "r390"
     ]
    },
    "ifrs-full_PowerGeneratingAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PowerGeneratingAssetsMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Power generating assets [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing assets that generate power. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r385"
     ]
    },
    "dei_PreCommencementIssuerTenderOffer": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "PreCommencementIssuerTenderOffer",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pre-commencement Issuer Tender Offer",
        "documentation": "Boolean flag that is true when the Form 8-K filing is intended to satisfy the filing obligation of the registrant as pre-commencement communications pursuant to Rule 13e-4(c) under the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r266"
     ]
    },
    "dei_PreCommencementTenderOffer": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "PreCommencementTenderOffer",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pre-commencement Tender Offer",
        "documentation": "Boolean flag that is true when the Form 8-K filing is intended to satisfy the filing obligation of the registrant as pre-commencement communications pursuant to Rule 14d-2(b) under the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r268"
     ]
    },
    "sbs_PreferenciaisPercentageOfShares": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PreferenciaisPercentageOfShares",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of shares, preferenciais"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PrincipalAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PrincipalAmount",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Principal amount"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PrincipalOfBorrowings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PrincipalOfBorrowings",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Principal of borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PrivateSectorMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PrivateSectorMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Private Sector [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProbabilityOfDefaultAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProbabilityOfDefaultAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Probability of default [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r245",
      "r254"
     ]
    },
    "ifrs-full_ProbabilityOfDefaultDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProbabilityOfDefaultDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Probability of default' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r245",
      "r254"
     ]
    },
    "sbs_ProbableScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProbableScenarioMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Probable Scenario [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProceedsFromDerivativeFinancialInstrumentsReceived": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProceedsFromDerivativeFinancialInstrumentsReceived",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative financial instruments - Paid/received"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProceedsFromIssuancesOfMediumTermNotes": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProceedsFromIssuancesOfMediumTermNotes",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Funding"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProductsAndServicesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProductsAndServicesAxis",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Products and services [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r206",
      "r240"
     ]
    },
    "ifrs-full_ProductsAndServicesDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProductsAndServicesDomain",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the entity's products and services. It also represents the standard value for the 'Products and services' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r206",
      "r240"
     ]
    },
    "sbs_ProfitBeforeIncomeTaxAndSocialContribution": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProfitBeforeIncomeTaxAndSocialContribution",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Profit before income and social contribution taxes",
        "label": "ProfitBeforeIncomeTaxAndSocialContribution"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_ProfitLossBeforeTax",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Profit from operations before financial income (expenses)",
        "label": "ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProfitLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProfitLoss",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 1.0
      },
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails",
      "http://sabesp.com.br/role/EquityDetails1",
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/StatementOfChangesInEquity",
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit for the year",
        "verboseLabel": "Profit for the period",
        "terseLabel": "Profit for the period"
       }
      },
      "en": {
       "role": {
        "documentation": "The total of income less expenses from continuing and discontinued operations, excluding the components of other comprehensive income. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r3",
      "r30",
      "r105",
      "r120",
      "r124",
      "r199",
      "r202",
      "r239",
      "r242"
     ]
    },
    "ifrs-full_ProfitLossBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProfitLossBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_ProfitLoss",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3",
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Profit before income tax and social contribution",
        "label": "Profit before taxes",
        "verboseLabel": "Income from operations before taxes"
       }
      },
      "en": {
       "role": {
        "documentation": "The profit (loss) before tax expense or income. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r170",
      "r214",
      "r215",
      "r257",
      "r258"
     ]
    },
    "ifrs-full_ProfitLossRecognisedOnExchangingConstructionServicesForIntangibleAsset2011": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProfitLossRecognisedOnExchangingConstructionServicesForIntangibleAsset2011",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": -1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Construction Margin on Intangible Assets arising from Concession Agreements",
        "label": "Profit (loss) recognised on exchanging construction services for intangible asset"
       }
      },
      "en": {
       "role": {
        "documentation": "The profit (loss) recognised on exchanging construction services for an intangible asset in service concession arrangements. [Refer: Service concession arrangements [domain]; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r211"
     ]
    },
    "sbs_ProfitOnSupplyGovernmentEntitiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProfitOnSupplyGovernmentEntitiesMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit On Supply Government Entities [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProgramContractCommitments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProgramContractCommitments",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Program Contract Commitments",
        "label": "ProgramContractCommitments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProgramContractsCommitmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProgramContractsCommitmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Program contracts \u0096 commitments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProgramContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProgramContractsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Program contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProgramaDeFormacaoDoPatrimonioDoServidorPublicoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProgramaDeFormacaoDoPatrimonioDoServidorPublicoMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Programa De Formacao Do Patrimonio Do Servidor Publico [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PropertiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PropertiesMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Properties [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PropertyPlantAndEquipment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PropertyPlantAndEquipment",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Property, plant and equipment",
        "verboseLabel": "Net",
        "periodStartLabel": "Property, plant, and equipment, beginning",
        "periodEndLabel": "Property, plant, and equipment, ending"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of tangible assets that: (a) are held for use in the production or supply of goods or services, for rental to others, or for administrative purposes; and (b) are expected to be used during more than one period. Note that right-of-use assets are not included. [Contrast: Property, plant and equipment including right-of-use assets]"
       }
      }
     },
     "auth_ref": [
      "r8",
      "r49"
     ]
    },
    "sbs_PropertyPlantAndEquipment1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PropertyPlantAndEquipment1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Cost",
        "label": "PropertyPlantAndEquipment1"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PropertyPlantAndEquipmentAccumulatedAmortization": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PropertyPlantAndEquipmentAccumulatedAmortization",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated depreciation"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProportionOfOwnershipInterestInJointVenture": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProportionOfOwnershipInterestInJointVenture",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage of equity interest"
       }
      },
      "en": {
       "role": {
        "documentation": "The proportion of ownership interest in a joint venture attributable to the entity. [Refer: Total for all joint ventures [member]]"
       }
      }
     },
     "auth_ref": [
      "r80",
      "r81",
      "r125"
     ]
    },
    "sbs_Provision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Provision",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Provisions, beginning",
        "periodEndLabel": "Provisions, ending",
        "label": "Provision"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionForConsentDecreeAndKnowledgeRetentionProgram": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionForConsentDecreeAndKnowledgeRetentionProgram",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision for Consent Decree (TAC), Knowledge Retention Program (KRP) and Incentivized Dismissal Program (IDP) and Voluntary Dismissal Program (VDP)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionForProfitSharingIi": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionForProfitSharingIi",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision for profit sharing (ii)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionForVacation": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionForVacation",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision for vacation"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionUsedOtherProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionUsedOtherProvision",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Use of the accrual"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionsAndInflationAdjustment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionsAndInflationAdjustment",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions and inflation adjustments on provisions"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProvisionsForEmployeeBenefits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ProvisionsForEmployeeBenefits",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provision for employee compensation"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of provisions for employee benefits. [Refer: Employee benefits expense; Provisions]"
       }
      }
     },
     "auth_ref": [
      "r26"
     ]
    },
    "sbs_ProvisionsGross": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionsGross",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Provisions",
        "label": "ProvisionsGross"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ProvisionsNet": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ProvisionsNet",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "ProvisionsNet"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicPrivatePartnership": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicPrivatePartnership",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Public-Private Partnership - PPP",
        "label": "PublicPrivatePartnership"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicPrivatePartnershipCurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicPrivatePartnershipCurrent",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Public-Private Partnership - PPP",
        "verboseLabel": "Current liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicPrivatePartnershipLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicPrivatePartnershipLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicPrivatePartnershipMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicPrivatePartnershipMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Public Private Partnership [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicPrivatePartnershipNoncurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicPrivatePartnershipNoncurrent",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noncurrent liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_PublicprivatePartnershipPpp": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "PublicprivatePartnershipPpp",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentLiabilities",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Public-Private Partnership - PPP",
        "label": "PublicprivatePartnershipPpp"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PurchaseOfIntangibleAssetsClassifiedAsInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "PurchaseOfIntangibleAssetsClassifiedAsInvestingActivities",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Acquisition of contract assets, intangible assets and property, plant and equipment",
        "label": "Purchase of intangible assets, classified as investing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for the purchases of intangible assets, classified as investing activities. [Refer: Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r234"
     ]
    },
    "ecd_PvpTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PvpTable",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pay vs Performance Disclosure [Table]"
       }
      }
     },
     "auth_ref": [
      "r322"
     ]
    },
    "ecd_PvpTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "PvpTableTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pay vs Performance Disclosure, Table"
       }
      }
     },
     "auth_ref": [
      "r322"
     ]
    },
    "sbs_RealizedAfter1YearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RealizedAfter1YearMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Realized After 1 Year [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RealizedWithin12MonthsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RealizedWithin12MonthsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Realized Within 12 Months [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ReclassificationAdjustmentsOnCashFlowHedgesNetOfTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ReclassificationAdjustmentsOnCashFlowHedgesNetOfTax",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Retained earnings (accumulated losses) on cash flow hedge, net of taxes",
        "label": "Reclassification adjustments on cash flow hedges, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of reclassification adjustments related to cash flow hedges, net of tax. Reclassification adjustments are amounts reclassified to profit (loss) in the current period that were recognised in other comprehensive income in the current or previous periods. [Refer: Cash flow hedges [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r36",
      "r175",
      "r176"
     ]
    },
    "sbs_RecognizedAsTaxesAndContributionsPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RecognizedAsTaxesAndContributionsPayable",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recognized as taxes and contributions payable"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RecognizedEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RecognizedEquity",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recognized equity"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ReconciliationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReconciliationsMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reconciliations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RecoveriesRecognized": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RecoveriesRecognized",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recoveries"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RecoveriesRecognizedInBadDebtExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RecoveriesRecognizedInBadDebtExpense",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Recoveries",
        "label": "RecoveriesRecognizedInBadDebtExpense"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_RecoveryOfErrCompDisclosureLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "RecoveryOfErrCompDisclosureLineItems",
     "auth_ref": [
      "r285",
      "r296",
      "r310",
      "r336"
     ]
    },
    "sbs_ReimbursementForRetirementAndPensionBenefitsPaidMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReimbursementForRetirementAndPensionBenefitsPaidMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reimbursement For Retirement And Pension Benefits Paid [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ReimbursementGESP2015Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReimbursementGESP2015Member",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reimbursement G E S P 2015 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RelatedPartyLoanAgreementBalancePricipal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RelatedPartyLoanAgreementBalancePricipal",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other assets, current"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RepaymentsOfBorrowingClassifiedAsFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RepaymentsOfBorrowingClassifiedAsFinancingActivities",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Amortization",
        "label": "RepaymentsOfBorrowingClassifiedAsFinancingActivities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ReportingCurrencyInWhichInformationIsDisplayedAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReportingCurrencyInWhichInformationIsDisplayedAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reporting Currency In Which Information Is Displayed [Axis]",
        "verboseLabel": "ReportingCurrencyInWhichInformationIsDisplayedAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ReportingCurrencyInWhichInformationIsDisplayedDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReportingCurrencyInWhichInformationIsDisplayedDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails"
     ],
     "auth_ref": []
    },
    "ecd_RestatementDateAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "RestatementDateAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restatement Determination Date [Axis]"
       }
      }
     },
     "auth_ref": [
      "r286",
      "r297",
      "r311",
      "r337"
     ]
    },
    "ecd_RestatementDeterminationDate": {
     "xbrltype": "dateItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "RestatementDeterminationDate",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restatement Determination Date"
       }
      }
     },
     "auth_ref": [
      "r287",
      "r298",
      "r312",
      "r338"
     ]
    },
    "ecd_RestatementDoesNotRequireRecoveryTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "RestatementDoesNotRequireRecoveryTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restatement does not require Recovery"
       }
      }
     },
     "auth_ref": [
      "r294",
      "r305",
      "r319",
      "r345"
     ]
    },
    "ifrs-full_RestrictedCashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RestrictedCashAndCashEquivalents",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentAssets",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/RestrictedCashDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restricted cash"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash and cash equivalents whose use or withdrawal is restricted. [Refer: Cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "sbs_RestrictedShares1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RestrictedShares1Member",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restricted Shares 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RestrictedSharesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RestrictedSharesMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Restricted Shares [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RestrictiveRatios": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RestrictiveRatios",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Covenants"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_RetainedEarnings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RetainedEarnings",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Retained earnings"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing the entity's cumulative undistributed earnings or deficit."
       }
      }
     },
     "auth_ref": [
      "r219",
      "r221"
     ]
    },
    "ifrs-full_RetainedEarningsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RetainedEarningsMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Retained earnings [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing an entity's cumulative undistributed earnings or deficit."
       }
      }
     },
     "auth_ref": [
      "r4",
      "r216"
     ]
    },
    "ifrs-full_ReturnOnPlanAssetsNetDefinedBenefitLiabilityAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ReturnOnPlanAssetsNetDefinedBenefitLiabilityAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expected return on the plan's assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease (increase) in the net defined benefit liability (asset) resulting from the return on plan assets, excluding amounts included in interest income or expense. The return on plan assets is interest, dividends and other revenue derived from the plan assets, together with realised and unrealised gains or losses on the plan assets, less any costs of managing plan assets and less any tax payable by the plan itself, other than tax included in the actuarial assumptions used to measure the present value of the defined benefit obligation. [Refer: Plan assets [member]; Net defined benefit liability (asset); Actuarial assumptions [domain]; Increase (decrease) in net defined benefit liability (asset) resulting from interest expense (income)]"
       }
      }
     },
     "auth_ref": [
      "r54"
     ]
    },
    "sbs_ReturnOnPlanAssetsNetDefinedBenefitLiabilityAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ReturnOnPlanAssetsNetDefinedBenefitLiabilityAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expected return of the plans assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Revenue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "Revenue",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "ifrs-full_GrossProfit",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails",
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating revenue",
        "verboseLabel": "Revenues",
        "terseLabel": "Net operating revenue"
       }
      },
      "en": {
       "role": {
        "documentation": "The income arising in the course of an entity's ordinary activities. Income is increases in assets, or decreases in liabilities, that result in increases in equity, other than those relating to contributions from holders of equity claims."
       }
      }
     },
     "auth_ref": [
      "r32",
      "r132",
      "r170",
      "r196",
      "r201",
      "r206",
      "r207",
      "r208",
      "r214",
      "r215",
      "r239"
     ]
    },
    "ifrs-full_RevenueAndOperatingIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RevenueAndOperatingIncome",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gross operating revenue"
       }
      },
      "en": {
       "role": {
        "documentation": "The aggregate amount of the entity's revenue and other operating income. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r381"
     ]
    },
    "ifrs-full_RevenueFromConstructionContracts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RevenueFromConstructionContracts",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Construction revenue"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of revenue arising from construction contracts. Construction contracts are contracts specifically negotiated for the construction of an asset or a combination of assets that are closely interrelated or interdependent in terms of their design, technology and function or their ultimate purpose or use. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_RevenueRecognisedOnExchangingConstructionServicesForFinancialAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RevenueRecognisedOnExchangingConstructionServicesForFinancialAsset",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial asset of the concession (ii)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of revenue recognised when construction services are exchanged for financial assets in service concession arrangements. [Refer: Service concession arrangements [domain]; Revenue from contracts with customers]"
       }
      }
     },
     "auth_ref": [
      "r211"
     ]
    },
    "sbs_RevenueSanitationServices": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RevenueSanitationServices",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue from sanitation services"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RightOfUseAssetsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RightOfUseAssetsNetMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Right Of Use Assets Net [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RightOfUseOtherAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RightOfUseOtherAssetsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Right of use \u0096 other assets [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_RightOfUsesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "RightOfUsesMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Right Of Uses [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_RightofuseAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "RightofuseAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total Leases and Right of use",
        "label": "Right-of-use assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that represent a lessee's right to use an underlying asset for the lease term that do not meet the definition of investment property. Underlying asset is an asset that is the subject of a lease, for which the right to use that asset has been provided by a lessor to a lessee."
       }
      }
     },
     "auth_ref": [
      "r146",
      "r151"
     ]
    },
    "ecd_Rule10b51ArrAdoptedFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "Rule10b51ArrAdoptedFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Rule 10b5-1 Arrangement Adopted"
       }
      }
     },
     "auth_ref": [
      "r354"
     ]
    },
    "ecd_Rule10b51ArrTrmntdFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "Rule10b51ArrTrmntdFlag",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Rule 10b5-1 Arrangement Terminated"
       }
      }
     },
     "auth_ref": [
      "r354"
     ]
    },
    "sbs_SABESPLuxMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SABESPLuxMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "S A B E S P Lux [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SABESPLuxembourgMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SABESPLuxembourgMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "S A B E S P Luxembourg [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SABESPMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SABESPMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "S A B E S P [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SabespOlimpiaMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SabespOlimpiaMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sabesp Olimpia [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SabesprevMaisMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SabesprevMaisMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sabesprev Mais [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SabesprevMaisPlanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SabesprevMaisPlanMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sabesprev Mais Plan [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SalariesAndPayrollCharges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SalariesAndPayrollCharges",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Salaries and payroll charges"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SalariesPayrollChargesAndBenefitsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SalariesPayrollChargesAndBenefitsMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Salaries Payroll Charges And Benefits [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SalesTaxOnRevenue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SalesTaxOnRevenue",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Regulation, Control and Oversight Fee (TRCF) (iii)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SanitationServicesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SanitationServicesMember",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails",
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sanitation Services [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SanitationServicesRevenue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SanitationServicesRevenue",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue from sanitation services (i)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SanitationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SanitationsMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sanitations [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SaoCaetanoDoSulMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SaoCaetanoDoSulMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sao Caetano Do Sul [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SaoCaetanodoSulAgreementMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SaoCaetanodoSulAgreementMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sao Caetanodo Sul Agreement [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SaoLourencoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SaoLourencoMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails2",
      "http://sabesp.com.br/role/IntangibleAssetsDetails3",
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sao Lourenco [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SaoPauloStateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SaoPauloStateMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sao Paulo State [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SchdeuleOfExpensesByNatureTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SchdeuleOfExpensesByNatureTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of operating costs and expenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleConciliationOfGrossOperatingRevenueAndNetOperatingRevenueTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of conciliation from gross operating income to net operating income"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfAccountsReceivableInterestOnCapitalPayableRevenueAndExpensesWithGovernmentTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of loan agreement through credit facility"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfAgingOfTradeReceivablesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfAgingOfTradeReceivablesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of aging of trade receivables"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfBorrowingsAndFinancingSubjectToDifferentInflationAdjustmentIndicesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfBorrowingsAndFinancingSubjectToDifferentInflationAdjustmentIndicesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of borrowings and financing subject to different inflation adjustment indices"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfCapitalManagementTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfCapitalManagementTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of capital management"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfCashAndCashEquivalentTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfCashAndCashEquivalentTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/CashAndCashEquivalentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of cash and cash equivalents"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfCashFlowHedgeStatementOfFinancialPositionAndIncomeStatementTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfCashFlowHedgeStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of cash flow hedge"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfChangesInNumberOfSharesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfChangesInNumberOfSharesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EquityTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of changes in the number of shares"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfCommitmentsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfCommitmentsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/CommitmentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of commitments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfContractAssetAndInstangibleAssetsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfContractAssetAndInstangibleAssetsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of contract asset and intangible assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfDeferredPISAndCofinsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfDeferredPISAndCofinsExplanatory",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of deferred taxes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfEffectOfDerivativesNotDesignatedHedgeAccountingTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfEffectOfDerivativesNotDesignatedHedgeAccountingTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of effect of derivatives not designated to hedge accounting"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfEmployeesBenefitsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfEmployeesBenefitsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of employees benefits"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfEquityValuationAdjustmentsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfEquityValuationAdjustmentsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EquityTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of equity valuation adjustments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfExpensesWithPublicPrivateTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfExpensesWithPublicPrivateTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of expenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfExposureToExchangeRiskTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfExposureToExchangeRiskTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of exposure to exchange risk"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfFinancialAssetResultingFromConcessionAgreementTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfFinancialAssetResultingFromConcessionAgreementTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial asset resulting from concession agreement"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfFinancialIncomeExpensesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfFinancialIncomeExpensesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/FinancialIncomeexpenseNetTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial income net"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfFinancialInvestmentsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfFinancialInvestmentsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial investments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfFinancialPositionTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfFinancialPositionTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial position balances"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfIncreaseDecreaseInExchangeRateTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfIncreaseDecreaseInExchangeRateTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of prices exchange variations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfIntangibleAssetsRecordedTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfIntangibleAssetsRecordedTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of intangible assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfJudicialBondsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfJudicialBondsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of judicial bonds"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfLoanAgreementThroughCreditFacilityTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfLoanAgreementThroughCreditFacilityTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of loan agreement through credits facility"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfObligationsAssumedLiabilitiesTableTeaxtBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfObligationsAssumedLiabilitiesTableTeaxtBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of obligations assumed of liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfObligationsMaturityTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfObligationsMaturityTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of obligations maturity"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfOperatingSegmentInformationTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfOperatingSegmentInformationTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of operating segment information"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfOtherOperatingIncomeExpensesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfOtherOperatingIncomeExpensesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of other operating income (expenses), net"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfPensionPlanBenefitsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfPensionPlanBenefitsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of pension plan benefits"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfReconciliationOfEstimatedHistoricalLossesOfIncomeTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfReconciliationOfEstimatedHistoricalLossesOfIncomeTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of estimated reconciliation"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfReconciliationOfExpensesWithPensionObligationsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfReconciliationOfExpensesWithPensionObligationsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of reconciliation of expenses with pension obligations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfSensitivityAnalysisOnInterestRateRiskTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfSensitivityAnalysisOnInterestRateRiskTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of sensitivity analysis on interest rate risk"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfServicesPayableTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfServicesPayableTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayableTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of service payable"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfShareBasedPaymentPlansFairValueTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfShareBasedPaymentPlansFairValueTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EquityTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of share based payment plans"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfShareCapitalTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfShareCapitalTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EquityTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of share capital"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfShareholderReturnsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfShareholderReturnsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EquityTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of shareholder returns"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfStatementOfFinancialPositionAndIncomeStatementTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DerivativeFinancialInstrumentsAndHedgingTransactionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial position and income statement"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfSupplementalCashFlowInformationTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfSupplementalCashFlowInformationTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of supplemental cash flow information"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ScheduleOfTradeReceivableAllowanceForDoubtfulAccountsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ScheduleOfTradeReceivableAllowanceForDoubtfulAccountsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of allowance for doubtful accounts"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SeasammMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SeasammMember",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Seasamm [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SecuredOvernightFinancingRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SecuredOvernightFinancingRateMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Secured Overnight Financing Rate [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_Security12bTitle": {
     "xbrltype": "securityTitleItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "Security12bTitle",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title of 12(b) Security",
        "documentation": "Title of a 12(b) registered security."
       }
      }
     },
     "auth_ref": [
      "r260"
     ]
    },
    "dei_Security12gTitle": {
     "xbrltype": "securityTitleItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "Security12gTitle",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title of 12(g) Security",
        "documentation": "Title of a 12(g) registered security."
       }
      }
     },
     "auth_ref": [
      "r264"
     ]
    },
    "dei_SecurityExchangeName": {
     "xbrltype": "edgarExchangeCodeItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "SecurityExchangeName",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Security Exchange Name",
        "documentation": "Name of the Exchange on which a security is registered."
       }
      }
     },
     "auth_ref": [
      "r263"
     ]
    },
    "dei_SecurityReportingObligation": {
     "xbrltype": "securityReportingObligationItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "SecurityReportingObligation",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Security Reporting Obligation",
        "documentation": "15(d), indicating whether the security has a reporting obligation under that section of the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r269"
     ]
    },
    "sbs_SegmentConsolidationItemAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SegmentConsolidationItemAxis",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment Consolidation Item [Axis]",
        "verboseLabel": "SegmentConsolidationItemAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SegmentConsolidationItemDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SegmentConsolidationItemDomain",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "auth_ref": []
    },
    "ifrs-full_SellingExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "SellingExpense",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfIncome": {
       "parentTag": "sbs_ProfitFromOperationsBeforeFinanceIncomeExpensesAndIncomeTaxAndSocialContribution",
       "weight": -1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails",
      "http://sabesp.com.br/role/StatementsOfIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Selling expenses",
        "negatedTerseLabel": "Selling expense",
        "label": "Selling expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense relating to selling activities of the entity."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_SellingGeneralAndAdministrativeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "SellingGeneralAndAdministrativeExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingSegmentInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Costs, selling, general and administrative expenses",
        "label": "Selling, general and administrative expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense relating to selling, general and administrative activities of the entity."
       }
      }
     },
     "auth_ref": [
      "r381"
     ]
    },
    "sbs_SellingGeneralAndAdministrativeExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SellingGeneralAndAdministrativeExpenses",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "[custom:SellingGeneralAndAdministrativeExpenses]",
        "label": "SellingGeneralAndAdministrativeExpenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SensitivityAnalysisAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SensitivityAnalysisAxis",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sensitivity Analysis [Axis]",
        "verboseLabel": "SensitivityAnalysisAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SensitivityAnalysisDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SensitivityAnalysisDomain",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "auth_ref": []
    },
    "sbs_SeriesOneMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SeriesOneMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Series 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SeriesThreeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SeriesThreeMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Series 3 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SeriesTwoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SeriesTwoMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Series 2 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ServiceContractsCommitmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ServiceContractsCommitmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Services contracts \u0096 Sao Paulo [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ServicesExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ServicesExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative",
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Outsourced services",
        "verboseLabel": "Provision of public water and sewage services"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense arising from services."
       }
      }
     },
     "auth_ref": [
      "r381"
     ]
    },
    "sbs_SetupOfReserves": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SetupOfReserves",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Legal reserve"
       }
      }
     },
     "auth_ref": []
    },
    "us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://fasb.org/us-gaap/2024",
     "localname": "ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "auth_ref": []
    },
    "sbs_ShareBasedPaymentOfRemainingLifeShareGranted": {
     "xbrltype": "durationItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ShareBasedPaymentOfRemainingLifeShareGranted",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maximum remaining life"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ShareBasedPaymentPlansMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ShareBasedPaymentPlansMember",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share Based Payment Plans [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SharebasedPayments": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SharebasedPayments",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share-based payment"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ShorttermEmployeeBenefitsAccruals": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ShorttermEmployeeBenefitsAccruals",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayableDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other services"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of accruals for employee benefits (other than termination benefits) that are expected to be settled wholly within twelve months after the end of the annual reporting period in which the employees render the related services. [Refer: Accruals classified as current]"
       }
      }
     },
     "auth_ref": [
      "r380"
     ]
    },
    "ifrs-full_ShorttermEmployeeBenefitsExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "ShorttermEmployeeBenefitsExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Short-term contracts"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense from employee benefits (other than termination benefits) that are expected to be settled wholly within twelve months after the end of the annual reporting period in which the employees render the related services."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "sbs_ShorttermFAUSP": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ShorttermFAUSP",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayableDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "FAUSP"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ShorttermMunicipalTransfers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ShorttermMunicipalTransfers",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/ServicesPayableDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Municipal Transfers",
        "label": "ShorttermMunicipalTransfers"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SignificantAccountingEstimatesAndJudgmentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SignificantAccountingEstimatesAndJudgmentsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Significant Accounting Estimates And Judgments"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SimpleInterest": {
     "xbrltype": "percentItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SimpleInterest",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInstrumentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Simple interest"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SocialSecuritysContributionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SocialSecuritysContributionMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Social Securitys Contribution [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SoftwareLicenseMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SoftwareLicenseMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Software License [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SoftwareLicensesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SoftwareLicensesMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Software Licenses [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_SolicitingMaterial": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "SolicitingMaterial",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Soliciting Material",
        "documentation": "Boolean flag that is true when the Form 8-K filing is intended to satisfy the filing obligation of the registrant as soliciting material pursuant to Rule 14a-12 under the Exchange Act."
       }
      }
     },
     "auth_ref": [
      "r267"
     ]
    },
    "ifrs-full_StatementOfCashFlowsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatementOfCashFlowsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of cash flows [abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementOfChangesInEquityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatementOfChangesInEquityAbstract",
     "auth_ref": []
    },
    "ifrs-full_StatementOfChangesInEquityTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatementOfChangesInEquityTable",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails",
      "http://sabesp.com.br/role/EquityDetails3",
      "http://sabesp.com.br/role/EquityDetails4",
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of changes in equity [table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to changes in equity."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "ifrs-full_StatementOfFinancialPositionAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatementOfFinancialPositionAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of financial position [abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatutoryReserve": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatutoryReserve",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statutory reserve"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing reserves created based on legal requirements."
       }
      }
     },
     "auth_ref": [
      "r379"
     ]
    },
    "ifrs-full_StatutoryReserveMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StatutoryReserveMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statutory reserve [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing reserves created based on legal requirements."
       }
      }
     },
     "auth_ref": [
      "r376"
     ]
    },
    "ecd_StkPrcOrTsrEstimationMethodTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "StkPrcOrTsrEstimationMethodTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/ErrCompDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Stock Price or TSR Estimation Method"
       }
      }
     },
     "auth_ref": [
      "r289",
      "r300",
      "r314",
      "r340"
     ]
    },
    "ifrs-full_StructuredDebtAmountContributedToFairValueOfPlanAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "StructuredDebtAmountContributedToFairValueOfPlanAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails8"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total structured investments"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount debt that has been structured to meet a particular investment objective contributes to the fair value of defined benefit plan assets. [Refer: Plan assets, at fair value; Defined benefit plans [domain]]"
       }
      }
     },
     "auth_ref": [
      "r229"
     ]
    },
    "sbs_SubtotalClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SubtotalClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subtotal Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SumamryOfChangesInIntangibleAssetsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SumamryOfChangesInIntangibleAssetsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of obligations assumed"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfActuarialAssumptionsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfActuarialAssumptionsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of actuarial assumptions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfAmountsRecognizedInIncomeStatementTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfAmountsRecognizedInIncomeStatementTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of amounts recognized in income statement"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfBenefitPlanExpensesRecognizedByEmployerTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfBenefitPlanExpensesRecognizedByEmployerTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of estimated expenses"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfBorrowingsAndFinancingCreditLimitedTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfBorrowingsAndFinancingCreditLimitedTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of borrowings and financing credit limits"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfBorrowingsAndFinancingOutstandingTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfBorrowingsAndFinancingOutstandingTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of borrowings and financing outstanding"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfBorrowingsPaymentScheduleTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfBorrowingsPaymentScheduleTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of borrowings payment schedule"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfBorrowingsTermsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfBorrowingsTermsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of borrowings terms"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfChangesInBorrowingsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfChangesInBorrowingsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of changes in borrowings"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfChangesInDeferredTaxesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfChangesInDeferredTaxesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of changes"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfChangesInPropertyPlantAndEquipmentTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfChangesInPropertyPlantAndEquipmentTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of changes in property, plant, and equipment"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfChangesInProvisionsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfChangesInProvisionsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of changes in provisions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfContractAssetsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfContractAssetsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of contract assets and other concession assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfCurrentTaxAssetsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfCurrentTaxAssetsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of current assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfCurrentTaxLiabilitiesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfCurrentTaxLiabilitiesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of current liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfDebenturesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfDebenturesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of convertible debentures"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfDeferredTaxesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfDeferredTaxesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Schedule of deferred taxes",
        "label": "SummaryOfDeferredTaxesTableTextBlock"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfEarningsPerShareBasicAndDilutedTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfEarningsPerShareBasicAndDilutedTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of earnings per share, basic and diluted"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfFinancialPositionDetailsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfFinancialPositionDetailsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of financial position details"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfGainsLossesDueToChangesInAssumptionsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfGainsLossesDueToChangesInAssumptionsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of (gains)/losses, due to changes in assumptions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfIncomeStatementImpactTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfIncomeStatementImpactTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of impact in the income statements"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfInvesteesFinancialStatementsAndEquityInterestTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfInvesteesFinancialStatementsAndEquityInterestTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of investees financial statements and equity interest"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfLawsuitsAndProceedingsThatResultedInProvisionsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of lawsuits and proceedings that resulted in provisions"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfLawsuitsDeemedAsContingentLiabilitiesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfLawsuitsDeemedAsContingentLiabilitiesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of lawsuits deemed as contingent liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfLiabilitiesAssumedTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfLiabilitiesAssumedTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of obligations assumed by the Company"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfPlanAssetsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfPlanAssetsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of plans assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfPropertyPlantAndEquipmentTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfPropertyPlantAndEquipmentTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of statement of financial position details"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfRealizationOfDeferredTaxesTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfRealizationOfDeferredTaxesTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of realization"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfReconciliationOfDefinedBenefitObligationsTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfReconciliationOfDefinedBenefitObligationsTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of reconciliation of defined benefit obligations"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfReconciliationOfEffectiveTaxRateTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfReconciliationOfEffectiveTaxRateTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of reconciliation of the effective tax rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfRestrictiveCovenantsRatiosTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfRestrictiveCovenantsRatiosTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of restrictive covenants ratios"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfRightOfUseTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfRightOfUseTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of right of use"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SummaryOfSensitivityAnalysisOfBenefitPlansTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SummaryOfSensitivityAnalysisOfBenefitPlansTableTextBlock",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Schedule of sensitivity analysis of"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_SupplierClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SupplierClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Supplier Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SurplusDeficitInPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "SurplusDeficitInPlan",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "(Deficit)/Surplus"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of any plan assets, less the present value of the defined benefit obligation. [Refer: Plan assets [member]]"
       }
      }
     },
     "auth_ref": [
      "r391"
     ]
    },
    "sbs_SurplusMinimumMandatory": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "SurplusMinimumMandatory",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Surplus minimum mandatory"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TJLPMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TJLPMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "T J L P [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TRMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TRMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "T R [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_TabularListTableTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TabularListTableTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tabular List, Table"
       }
      }
     },
     "auth_ref": [
      "r333"
     ]
    },
    "ifrs-full_TaxBenefitArisingFromPreviouslyUnrecognisedTaxLossTaxCreditOrTemporaryDifferenceOfPriorPeriodUsedToReduceCurrentTaxExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TaxBenefitArisingFromPreviouslyUnrecognisedTaxLossTaxCreditOrTemporaryDifferenceOfPriorPeriodUsedToReduceCurrentTaxExpense",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax benefit from interest on equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of benefit arising from a previously unrecognised tax loss, tax credit or temporary difference of a prior period that is used to reduce current tax expense. [Refer: Temporary differences [member]; Unused tax losses [member]; Unused tax credits [member]]"
       }
      }
     },
     "auth_ref": [
      "r223"
     ]
    },
    "sbs_TaxClaimMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxClaimMember",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails",
      "http://sabesp.com.br/role/ProvisionsDetails1",
      "http://sabesp.com.br/role/ProvisionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax Claim [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxExemptBeneficiaries": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxExemptBeneficiaries",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax exempt beneficiaries"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxExpenseMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxExpenseMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax Expense [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxExpensesIncomeAtApplicableTaxRate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxExpensesIncomeAtApplicableTaxRate",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Estimated expense at statutory rate"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxProvisionMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax Provision [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxProvisionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxProvisionsMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tax Provisions [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TaxRateEffectOfAdjustmentsForCurrentTaxOfPriorPeriods": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TaxRateEffectOfAdjustmentsForCurrentTaxOfPriorPeriods",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current taxes"
       }
      },
      "en": {
       "role": {
        "documentation": "Tax rate effect on the reconciliation between the average effective tax rate and the applicable tax rate resulting from adjustments for the current tax of prior periods. [Refer: Average effective tax rate; Applicable tax rate; Adjustments for current tax of prior periods]"
       }
      }
     },
     "auth_ref": [
      "r382"
     ]
    },
    "ifrs-full_TaxRateEffectOfRevenuesExemptFromTaxation": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TaxRateEffectOfRevenuesExemptFromTaxation",
     "presentation": [
      "http://sabesp.com.br/role/OperatingRevenueDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Tariffs revenue"
       }
      },
      "en": {
       "role": {
        "documentation": "The tax rate effect on the reconciliation between the average effective tax rate and the applicable tax rate resulting from revenue that is exempt from taxation. [Refer: Average effective tax rate; Applicable tax rate]"
       }
      }
     },
     "auth_ref": [
      "r43"
     ]
    },
    "sbs_TaxaDeJurosALongoPrazosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxaDeJurosALongoPrazosMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxa De Juros A Longo Prazos [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TaxableIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TaxableIncome",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Taxable income"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TemporaryDifferenceMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TemporaryDifferenceMember",
     "presentation": [
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Temporary differences [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for differences between the carrying amount of an asset or liability in the statement of financial position and its tax base. Temporary differences may be either: (a) taxable temporary differences; or (b) deductible temporary differences. [Refer: Carrying amount [member]]"
       }
      }
     },
     "auth_ref": [
      "r46"
     ]
    },
    "ifrs-full_TemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsAxis",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Temporary difference, unused tax losses and unused tax credits [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r46"
     ]
    },
    "ifrs-full_TemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TemporaryDifferenceUnusedTaxLossesAndUnusedTaxCreditsDomain",
     "presentation": [
      "http://sabesp.com.br/role/DeferredPiscofinsTaxesDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails1",
      "http://sabesp.com.br/role/DeferredTaxesAndContributionsDetails2",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetailsNarrative",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails",
      "http://sabesp.com.br/role/TaxesAndContributionsDetails1"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for temporary differences, unused tax losses and unused tax credits. It also represents the standard value for the 'Temporary difference, unused tax losses and unused tax credits' axis if no other member is used. [Refer: Temporary differences [member]; Unused tax credits [member]; Unused tax losses [member]]"
       }
      }
     },
     "auth_ref": [
      "r46"
     ]
    },
    "sbs_ThirtyFiveMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyFiveMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Five [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtyFourMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyFourMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Four [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtyFourThirtyFiveAndThirtySixIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyFourThirtyFiveAndThirtySixIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Four Thirty Five And Thirty Six Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtyIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtySevenIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtySevenIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Seven Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtySevenIssueDebenturesOneMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtySevenIssueDebenturesOneMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Seven Issue Debentures One [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtySevenIssueDebenturesTwoMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtySevenIssueDebenturesTwoMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Seven Issue Debentures Two [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtySixMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtySixMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Six [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtyThreeDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyThreeDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Three Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_ThirtyThreeIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "ThirtyThreeIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Thirty Three Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TitleOfInitiallyAppliedIFRS": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TitleOfInitiallyAppliedIFRS",
     "presentation": [
      "http://sabesp.com.br/role/ChangesInAccountingPracticesAndDisclosuresDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Standard"
       }
      },
      "en": {
       "role": {
        "documentation": "The title of an initially applied IFRS. [Refer: IFRSs [member]]"
       }
      }
     },
     "auth_ref": [
      "r113"
     ]
    },
    "sbs_Total": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "Total",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total",
        "label": "Total [Default Label]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalAdditionsToIntangibleAssetsAsPerStatementOfCashFlows": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalAdditionsToIntangibleAssetsAsPerStatementOfCashFlows",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total additions to intangible assets and contract assets according to statement of cash flows"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalAdditionsToPropertyPlantAndEquipmentNote": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalAdditionsToPropertyPlantAndEquipmentNote",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/SupplementalCashFlowInformationDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total additions to property, plant and equipment (Note 16 (b))"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "TotalAssets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalCapital": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalCapital",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total capital (shareholders plus providers of capital)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalExpense",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total",
        "label": "TotalExpense"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalLeasesAndRightOfUse": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalLeasesAndRightOfUse",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Total Leases and Right of use",
        "label": "TotalLeasesAndRightOfUse"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TotalReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalReceivables",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total receivables"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_TotalShareholderRtnAmt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TotalShareholderRtnAmt",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total Shareholder Return Amount"
       }
      }
     },
     "auth_ref": [
      "r325"
     ]
    },
    "ecd_TotalShareholderRtnVsPeerGroupTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TotalShareholderRtnVsPeerGroupTextBlock",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/PvpDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total Shareholder Return Vs Peer Group"
       }
      }
     },
     "auth_ref": [
      "r332"
     ]
    },
    "sbs_TotalingProposedDividends": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TotalingProposedDividends",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Totaling proposed dividends"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TradeAndOtherCurrentPayables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TradeAndOtherCurrentPayables",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade payables and contractors",
        "label": "Trade and other current payables"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current trade payables and current other payables. [Refer: Current trade payables; Other current payables]"
       }
      }
     },
     "auth_ref": [
      "r14"
     ]
    },
    "ifrs-full_TradeAndOtherPayablesToTradeSuppliers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TradeAndOtherPayablesToTradeSuppliers",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_CurrentLiabilities",
       "weight": 1.0,
       "order": 1.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trade payables and contractors"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of payment due to suppliers for goods and services used in the entity's business."
       }
      }
     },
     "auth_ref": [
      "r380"
     ]
    },
    "sbs_TradeReceivable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TradeReceivable",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Total trade receivables"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TradeReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TradeReceivables",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails",
      "http://sabesp.com.br/role/TradeReceivablesDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subtotal",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount due from customers for goods and services sold."
       }
      }
     },
     "auth_ref": [
      "r218"
     ]
    },
    "sbs_TradeReceivables1": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TradeReceivables1",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Trade receivables",
        "label": "TradeReceivables1"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TradeReceivablesJudicialBondsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TradeReceivablesJudicialBondsAxis",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trade Receivables Judicial Bonds [Axis]",
        "verboseLabel": "TradeReceivablesJudicialBondsAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TradeReceivablesJudicialBondsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TradeReceivablesJudicialBondsDomain",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails4"
     ],
     "auth_ref": []
    },
    "ecd_TradingArrAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TradingArrAxis",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trading Arrangement [Axis]"
       }
      }
     },
     "auth_ref": [
      "r353"
     ]
    },
    "ecd_TradingArrByIndTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TradingArrByIndTable",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trading Arrangements, by Individual [Table]"
       }
      }
     },
     "auth_ref": [
      "r355"
     ]
    },
    "dei_TradingSymbol": {
     "xbrltype": "tradingSymbolItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "TradingSymbol",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trading Symbol",
        "documentation": "Trading symbol of an instrument as listed on an exchange."
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TransactionPreferredAcquisition": {
     "xbrltype": "sharesItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TransactionPreferredAcquisition",
     "presentation": [
      "http://sabesp.com.br/role/EventsAfterReportingPeriodDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transaction acquisition"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TransferOfIntangibleAsset": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TransferOfIntangibleAsset",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfer of intangible asset"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TransferToSoPauloMunicipalGovernment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TransferToSoPauloMunicipalGovernment",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_AdjustmentsForReconcileProfitLoss",
       "weight": 1.0,
       "order": 15.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Municipal Transfers"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TransfersOfWorksToFinancialAssetOfConcession": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TransfersOfWorksToFinancialAssetOfConcession",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ContractAssetsAndOtherConcessionAssetsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers of works to financial asset of the concession"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TransfersUnderFinanceAgreementsFromEntityRelatedPartyTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TransfersUnderFinanceAgreementsFromEntityRelatedPartyTransactions",
     "presentation": [
      "http://sabesp.com.br/role/Related-partyBalancesAndTransactionsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Principal plus accumulated interest along with second installment of concession fee"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of transfers under finance agreements from the entity in related party transactions, including loans and equity contributions in cash or in kind. [Refer: Total for all related parties [member]]"
       }
      }
     },
     "auth_ref": [
      "r231"
     ]
    },
    "sbs_TransportEquipmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TransportEquipmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails",
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transport Equipments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_TrdArrAdoptionDate": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrAdoptionDate",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adoption Date"
       }
      }
     },
     "auth_ref": [
      "r356"
     ]
    },
    "ecd_TrdArrDuration": {
     "xbrltype": "durationItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrDuration",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Arrangement Duration"
       }
      }
     },
     "auth_ref": [
      "r357"
     ]
    },
    "ecd_TrdArrExpirationDate": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrExpirationDate",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expiration Date"
       }
      }
     },
     "auth_ref": [
      "r357"
     ]
    },
    "ecd_TrdArrIndName": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrIndName",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Name",
        "label": "Trading Arrangement, Individual Name"
       }
      }
     },
     "auth_ref": [
      "r355"
     ]
    },
    "ecd_TrdArrIndTitle": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrIndTitle",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title"
       }
      }
     },
     "auth_ref": [
      "r355"
     ]
    },
    "ecd_TrdArrTerminationDate": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "TrdArrTerminationDate",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Termination Date"
       }
      }
     },
     "auth_ref": [
      "r356"
     ]
    },
    "sbs_TreasuryShare": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TreasuryShare",
     "crdr": "credit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Treasury shares",
        "label": "TreasuryShare"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TreasuryShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TreasuryShares",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_Equity",
       "weight": -1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/EquityDetailsNarrative",
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Treasury shares",
        "label": "Treasury share"
       }
      },
      "en": {
       "role": {
        "documentation": "An entity\u2019s own equity instruments, held by the entity or other members of the consolidated group."
       }
      }
     },
     "auth_ref": [
      "r82",
      "r219"
     ]
    },
    "ifrs-full_TreasurySharesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TreasurySharesMember",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Treasury shares [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the entity\u2019s own equity instruments, held by the entity or other members of the consolidated group."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "sbs_TreasutyShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TreasutyShares",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Treasury shares"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TreatmentSuppliesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TreatmentSuppliesMember",
     "presentation": [
      "http://sabesp.com.br/role/OperatingCostsAndExpensesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Treatment Supplies [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyEightIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyEightIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Eight Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentySecondIssueDebenturesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentySecondIssueDebenturesMember",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Second Issue Debentures [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyThirtyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyThirtyMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Thirty [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyThirtyOneToTwentyFortyEightMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyThirtyOneToTwentyFortyEightMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Thirty One To Twenty Forty Eight [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyTwentyEightMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyTwentyEightMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Twenty Eight [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyTwentyNineMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyTwentyNineMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Twenty Nine [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyTwentySevenMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyTwentySevenMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Twenty Seven [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_TwentyTwentySixMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "TwentyTwentySixMember",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails4"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twenty Twenty Six [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TypesOfCustomersAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfCustomersAxis",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types of customers [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r241"
     ]
    },
    "ifrs-full_TypesOfCustomersDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfCustomersDomain",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all types of customers. It also represents the standard value for the 'Types of customers' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r241"
     ]
    },
    "ifrs-full_TypesOfFinancialAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfFinancialAssetsAxis",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types of financial assets [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r192",
      "r193"
     ]
    },
    "ifrs-full_TypesOfFinancialAssetsDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfFinancialAssetsDomain",
     "presentation": [
      "http://sabesp.com.br/role/FinancialAssetIndemnityDetailsNarrative",
      "http://sabesp.com.br/role/FinancialAssetOfConcessionDetails"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for aggregated types of financial assets. It also represents the standard value for the 'Types of financial assets' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r192",
      "r193"
     ]
    },
    "ifrs-full_TypesOfInterestRatesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfInterestRatesAxis",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types of interest rates [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r402"
     ]
    },
    "ifrs-full_TypesOfInterestRatesDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfInterestRatesDomain",
     "presentation": [
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails3",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails5",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetails6",
      "http://sabesp.com.br/role/BorrowingsAndFinancingDetailsNarrative",
      "http://sabesp.com.br/role/CashAndCashEquivalentsDetailsNarrative",
      "http://sabesp.com.br/role/FinancialInvestmentsDetailsNarrative",
      "http://sabesp.com.br/role/RiskManagementDetails2"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all types of interest rates. It also represents the standard value for the 'Types of interest rates' axis if no other member is used. [Refer: Interest rate risk [member]]"
       }
      }
     },
     "auth_ref": [
      "r402"
     ]
    },
    "ifrs-full_TypesOfInvestmentPropertyAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfInvestmentPropertyAxis",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types of investment property [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_TypesOfInvestmentPropertyDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfInvestmentPropertyDomain",
     "presentation": [
      "http://sabesp.com.br/role/InvestmentsDetails",
      "http://sabesp.com.br/role/InvestmentsDetailsNarrative"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Types of investment property' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r377"
     ]
    },
    "ifrs-full_TypesOfRisksAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfRisksAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types of risks [axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r158",
      "r159",
      "r160",
      "r162",
      "r173",
      "r179",
      "r180",
      "r213"
     ]
    },
    "ifrs-full_TypesOfRisksDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "TypesOfRisksDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en": {
       "role": {
        "documentation": "This member stands for all types of risks. It also represents the standard value for the 'Types of risks' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r158",
      "r159",
      "r160",
      "r162",
      "r173",
      "r179",
      "r180",
      "r213"
     ]
    },
    "sbs_URAE1Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "URAE1Member",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "U R A E 1 [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_UnbilledSupplyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "UnbilledSupplyMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unbilled Supply [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ecd_UndrlygSecurityMktPriceChngPct": {
     "xbrltype": "pureItemType",
     "nsuri": "http://xbrl.sec.gov/ecd/2024",
     "localname": "UndrlygSecurityMktPriceChngPct",
     "presentation": [
      "http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Underlying Security Market Price Change"
       }
      }
     },
     "auth_ref": [
      "r352"
     ]
    },
    "sbs_UnusedProvisionReversedOtherProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "UnusedProvisionReversedOtherProvision",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/ProvisionsDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amounts not used (reversal)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_VIVESTMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "VIVESTMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "V I V E S T [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_VIVESTPlanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "VIVESTPlanMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails10"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "V I V E S T Plan [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_VariableInterestRateAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "VariableInterestRateAxis",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Variable Interest Rate [Axis]",
        "verboseLabel": "VariableInterestRateAxis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_VariableInterestRateDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "VariableInterestRateDomain",
     "presentation": [
      "http://sabesp.com.br/role/RiskManagementDetails3"
     ],
     "auth_ref": []
    },
    "ifrs-full_VehiclesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "VehiclesMember",
     "presentation": [
      "http://sabesp.com.br/role/IntangibleAssetsDetails5"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Vehicles [member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of property, plant and equipment representing vehicles used in the entity's operations, specifically to include aircraft, motor vehicles and ships. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r385"
     ]
    },
    "sbs_VoluntaryDismissalProgram": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "VoluntaryDismissalProgram",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails": {
       "parentTag": "sbs_Total",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/LaborAndSocialObligationsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Voluntary Dismissal Program - VDP (iv)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WageIncreaseRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WageIncreaseRateMember",
     "presentation": [
      "http://sabesp.com.br/role/PensionPlanObligationsDetails6"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Wage Increase Rate [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WaterNationalAgencyNoncurrent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WaterNationalAgencyNoncurrent",
     "crdr": "debit",
     "calculation": {
      "http://sabesp.com.br/role/StatementsOfFinancialPosition": {
       "parentTag": "ifrs-full_NoncurrentAssets",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://sabesp.com.br/role/StatementsOfFinancialPosition"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Water and Basic Sanitation National Agency - ANA"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_WeightedAverageShares": {
     "xbrltype": "sharesItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "WeightedAverageShares",
     "presentation": [
      "http://sabesp.com.br/role/EarningsPerShareDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Weighted average number of common shares issued for basic earnings per share"
       }
      },
      "en": {
       "role": {
        "documentation": "The number of ordinary shares outstanding at the beginning of the period, adjusted by the number of ordinary shares bought back or issued during the period multiplied by a time-weighting factor."
       }
      }
     },
     "auth_ref": [
      "r85"
     ]
    },
    "sbs_WholesaleCustomersMunicipalGovernmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WholesaleCustomersMunicipalGovernmentsMember",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Wholesale Customers Municipal Governments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WithholdingIncomeTaxIrrfOnInterestOnEquityAssignedAsMandatoryMinimumDividends": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WithholdingIncomeTaxIrrfOnInterestOnEquityAssignedAsMandatoryMinimumDividends",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Withholding Income Tax (IRRF) on interest on equity assigned as mandatory minimum dividends (December 19, 2025)"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WithholdingIncomeTaxOnInterestOnCapitalAttributableAsMinimumMandatoryDividends": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WithholdingIncomeTaxOnInterestOnCapitalAttributableAsMinimumMandatoryDividends",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/StatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Withholding Income Tax (IRRF) on interest on equity assigned as mandatory minimum dividends"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WithholdingsIncomeTaxMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WithholdingsIncomeTaxMember",
     "presentation": [
      "http://sabesp.com.br/role/TaxesAndContributionsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Withholdings Income Tax [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_WritedownsReversalsOfPropertyPlantAndEquipment": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2024-03-27/ifrs-full",
     "localname": "WritedownsReversalsOfPropertyPlantAndEquipment",
     "presentation": [
      "http://sabesp.com.br/role/PropertyPlantAndEquipmentDetails1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Write-offs and disposals"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount recognised resulting from the write-down of property, plant and equipment to its recoverable amount or reversals of those write-downs. [Refer: Property, plant and equipment]"
       }
      }
     },
     "auth_ref": [
      "r37"
     ]
    },
    "sbs_WriteoffOfOperatingAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WriteoffOfOperatingAssets",
     "crdr": "debit",
     "presentation": [
      "http://sabesp.com.br/role/OtherOperatingIncomeExpensesNetDetailsNarrative"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Write-off of operating assets"
       }
      }
     },
     "auth_ref": []
    },
    "sbs_WriteoffsDuringPeriodForBadAndDoubtfulDebtsForThirdPartyTransaction": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "WriteoffsDuringPeriodForBadAndDoubtfulDebtsForThirdPartyTransaction",
     "crdr": "credit",
     "presentation": [
      "http://sabesp.com.br/role/TradeReceivablesDetails3"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Write-offs"
       }
      }
     },
     "auth_ref": []
    },
    "dei_WrittenCommunications": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2024",
     "localname": "WrittenCommunications",
     "presentation": [
      "http://sabesp.com.br/role/Cover"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Written Communications",
        "documentation": "Boolean flag that is true when the Form 8-K filing is intended to satisfy the filing obligation of the registrant as written communications pursuant to Rule 425 under the Securities Act."
       }
      }
     },
     "auth_ref": [
      "r372"
     ]
    },
    "sbs_XPInvestimentosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://sabesp.com.br/20251231",
     "localname": "XPInvestimentosMember",
     "presentation": [
      "http://sabesp.com.br/role/FinancialInvestmentsDetails"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "X P Investimentos [Member]"
       }
      }
     },
     "auth_ref": []
    }
   }
  }
 },
 "std_ref": {
  "r0": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "103",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_103&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r1": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "104",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_104&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r2": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "106",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_106_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r3": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_106_d_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r4": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "106",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_106&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r5": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "107",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_107&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r6": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "117",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_117&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r7": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "51",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_51_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r8": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r9": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r10": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r11": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r12": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r13": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r14": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "k",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_k&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r15": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "l",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_l&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r16": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "n",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_n&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r17": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "54",
   "Subparagraph": "o",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_54_o&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r18": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "55",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_55&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r19": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "56",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_56&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r20": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "61",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_61_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r21": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "61",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_61_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r22": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "61",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_61&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r23": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "66",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_66&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r24": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "69",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_69&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r25": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "7",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_7&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r26": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "78",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_78_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r27": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "78",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_78_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r28": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "79",
   "Subparagraph": "a",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_79_a_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r29": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "79",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_79_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r30": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "81A",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_81A_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r31": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "81A",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_81A_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r32": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "82",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_82_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r33": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "82",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_82_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r34": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "82",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_82_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r35": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "91",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_91_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r36": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "92",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_92&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r37": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "98",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_98_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r38": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "99",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_99&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r39": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "10",
   "IssueDate": "2024-01-01",
   "Paragraph": "21",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=10&code=ifrs-tx-2024-en-r&anchor=para_21&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r40": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "10",
   "IssueDate": "2024-01-01",
   "Section": "Disclosure",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=10&code=ifrs-tx-2024-en-r&doctype=Standard&dita_xref=IAS10_g17-22_TI",
   "URIDate": "2024-03-27"
  },
  "r41": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "79",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_79&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r42": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "c",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_c_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r43": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "c",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_c_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r44": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_g_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r45": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_g_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r46": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r47": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "73",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_73_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r48": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "73",
   "Subparagraph": "e",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_73_e_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r49": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "73",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_73_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r50": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "73",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_73&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r51": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "138",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_138&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r52": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r53": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r54": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "c",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_c_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r55": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "c",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_c_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r56": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r57": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r58": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r59": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "141",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_141_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r60": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "145",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_145_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r61": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "145",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_145&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r62": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "147",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_147_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r63": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "148",
   "Subparagraph": "d",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_148_d_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r64": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "2",
   "IssueDate": "2024-01-01",
   "Paragraph": "36",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=2&code=ifrs-tx-2024-en-r&anchor=para_36_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r65": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2024-en-r&anchor=para_53&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r66": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2024-01-01",
   "Paragraph": "57",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2024-en-r&anchor=para_57_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r67": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "17",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_17_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r68": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "17",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_17_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r69": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "17",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_17&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r70": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "18",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_18_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r71": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "18",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_18&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r72": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "19",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_19&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r73": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r74": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Section": "Disclosures",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&doctype=Standard&dita_xref=IAS24_g13-24_TI",
   "URIDate": "2024-03-27"
  },
  "r75": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2024-01-01",
   "Paragraph": "35",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2024-en-r&anchor=para_35_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r76": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2024-01-01",
   "Paragraph": "35",
   "Subparagraph": "b",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2024-en-r&anchor=para_35_b_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r77": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2024-01-01",
   "Paragraph": "35",
   "Subparagraph": "b",
   "Clause": "vi",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2024-en-r&anchor=para_35_b_vi&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r78": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2024-01-01",
   "Paragraph": "35",
   "Subparagraph": "b",
   "Clause": "viii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2024-en-r&anchor=para_35_b_viii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r79": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2024-01-01",
   "Paragraph": "36",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2024-en-r&anchor=para_36_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r80": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "27",
   "IssueDate": "2024-01-01",
   "Paragraph": "16",
   "Subparagraph": "b",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=27&code=ifrs-tx-2024-en-r&anchor=para_16_b_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r81": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "27",
   "IssueDate": "2024-01-01",
   "Paragraph": "17",
   "Subparagraph": "b",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=27&code=ifrs-tx-2024-en-r&anchor=para_17_b_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r82": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "32",
   "IssueDate": "2024-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=32&code=ifrs-tx-2024-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r83": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2024-01-01",
   "Paragraph": "66",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2024-en-r&anchor=para_66&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r84": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2024-01-01",
   "Paragraph": "67",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2024-en-r&anchor=para_67&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r85": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2024-01-01",
   "Paragraph": "70",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2024-en-r&anchor=para_70_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r86": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2024-01-01",
   "Section": "Disclosure",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2024-en-r&doctype=Standard&dita_xref=IAS33_g70-73A_TI",
   "URIDate": "2024-03-27"
  },
  "r87": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "34",
   "IssueDate": "2024-01-01",
   "Paragraph": "16A",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=34&code=ifrs-tx-2024-en-r&anchor=para_16A_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r88": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "36",
   "IssueDate": "2024-01-01",
   "Paragraph": "126",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=36&code=ifrs-tx-2024-en-r&anchor=para_126&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r89": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "36",
   "IssueDate": "2024-01-01",
   "Paragraph": "130",
   "Subparagraph": "d",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=36&code=ifrs-tx-2024-en-r&anchor=para_130_d_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r90": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2024-01-01",
   "Paragraph": "84",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2024-en-r&anchor=para_84_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r91": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2024-01-01",
   "Paragraph": "84",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2024-en-r&anchor=para_84_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r92": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2024-01-01",
   "Paragraph": "84",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2024-en-r&anchor=para_84&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r93": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2024-01-01",
   "Paragraph": "86",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2024-en-r&anchor=para_86_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r94": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "118",
   "Subparagraph": "e",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_118_e_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r95": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "118",
   "Subparagraph": "e",
   "Clause": "vi",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_118_e_vi&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r96": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "118",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_118_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r97": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "118",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_118&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r98": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "124",
   "Subparagraph": "a",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_124_a_iii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r99": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2024-01-01",
   "Paragraph": "32A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2024-en-r&anchor=para_32A&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r100": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2024-01-01",
   "Paragraph": "76",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2024-en-r&anchor=para_76_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r101": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2024-01-01",
   "Paragraph": "76",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2024-en-r&anchor=para_76&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r102": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2024-01-01",
   "Paragraph": "79",
   "Subparagraph": "d",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2024-en-r&anchor=para_79_d_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r103": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2024-01-01",
   "Paragraph": "79",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2024-en-r&anchor=para_79_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r104": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "10",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_10&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r105": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "18",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_18_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r106": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r107": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "31",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_31&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r108": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r109": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "42A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_42A&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r110": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "42B",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_42B&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r111": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "45",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_45&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r112": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "50",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_50_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r113": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r114": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r115": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r116": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r117": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "30",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_30_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r118": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "39",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2024-en-r&anchor=para_39&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r119": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "24",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_24_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r120": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "24",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_24_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r121": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "30",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_30_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r122": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "30",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_30&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r123": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "32",
   "Subparagraph": "a",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_32_a_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r124": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "32",
   "Subparagraph": "a",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2024-en-r&anchor=para_32_a_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r125": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "21",
   "Subparagraph": "a",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_21_a_iv&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r126": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_a&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r127": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_i&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r128": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_ii&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r129": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_iii&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r130": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_iv&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r131": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "ix",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_ix&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r132": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "v",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B12_b_v&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r133": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B13",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B13_a&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r134": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B13",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B13_d&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r135": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B13",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B13_g&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r136": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B16",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B16&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r137": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2024-01-01",
   "Paragraph": "93",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2024-en-r&anchor=para_93_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r138": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2024-01-01",
   "Paragraph": "93",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2024-en-r&anchor=para_93_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r139": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2024-01-01",
   "Paragraph": "93",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2024-en-r&anchor=para_93_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r140": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2024-01-01",
   "Paragraph": "93",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2024-en-r&anchor=para_93&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r141": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "105",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_105&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r142": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "114",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_114&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r143": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "116",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_116_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r144": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "119",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_119&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r145": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "120",
   "Subparagraph": "b",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_120_b_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r146": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "47",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_47_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r147": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r148": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r149": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r150": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r151": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "Subparagraph": "j",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53_j&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r152": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "53",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_53&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r153": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "94",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_94&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r154": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "97",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2024-en-r&anchor=para_97&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r155": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "109",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_109&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r156": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "109A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_109A&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r157": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "120",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_120&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r158": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "124",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_124&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r159": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "125",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_125&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r160": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "127",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_127&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r161": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "128",
   "Subparagraph": "a",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_128_a_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r162": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "128",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_128_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r163": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "132",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_132_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r164": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "C32",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_C32&doctype=Appendix&subtype=C",
   "URIDate": "2024-03-27"
  },
  "r165": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "2",
   "IssueDate": "2024-01-01",
   "Paragraph": "45",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=2&code=ifrs-tx-2024-en-r&anchor=para_45_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r166": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "2",
   "IssueDate": "2024-01-01",
   "Paragraph": "47",
   "Subparagraph": "a",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=2&code=ifrs-tx-2024-en-r&anchor=para_47_a_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r167": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "3",
   "IssueDate": "2024-01-01",
   "Paragraph": "B64",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=3&code=ifrs-tx-2024-en-r&anchor=para_B64_c&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r168": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "3",
   "IssueDate": "2024-01-01",
   "Paragraph": "B64",
   "Subparagraph": "f",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=3&code=ifrs-tx-2024-en-r&anchor=para_B64_f_iv&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r169": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "3",
   "IssueDate": "2024-01-01",
   "Paragraph": "B64",
   "Subparagraph": "h",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=3&code=ifrs-tx-2024-en-r&anchor=para_B64_h_i&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r170": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "5",
   "IssueDate": "2024-01-01",
   "Paragraph": "33",
   "Subparagraph": "b",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=5&code=ifrs-tx-2024-en-r&anchor=para_33_b_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r171": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "13C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_13C&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r172": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "Subparagraph": "a",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20_a_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r173": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "21C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_21C&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r174": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "23B",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_23B_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r175": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "24C",
   "Subparagraph": "b",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_24C_b_iv&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r176": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "24E",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_24E_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r177": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "25",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_25&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r178": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "31",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_31&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r179": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "33",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_33&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r180": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r181": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35H",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35H&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r182": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35I",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35I&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r183": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35K",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35K_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r184": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35K",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35K&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r185": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35M",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35M&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r186": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "36",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_36&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r187": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "42E",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_42E_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r188": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "42I",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_42I&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r189": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "6",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_6&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r190": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "7",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_7&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r191": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "8",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_8_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r192": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B51",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B51&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r193": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B52",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B52&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r194": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Section": "Defined terms",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&doctype=Appendix&subtype=A&dita_xref=IFRS07_APPA_TI",
   "URIDate": "2024-03-27"
  },
  "r195": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Section": "Scope",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&doctype=Standard&dita_xref=IFRS07_g3-5A_TI",
   "URIDate": "2024-03-27"
  },
  "r196": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "23",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_23_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r197": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "23",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_23_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r198": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "23",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_23_h&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r199": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "23",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_23&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r200": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "24",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_24_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r201": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r202": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r203": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r204": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r205": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r206": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "32",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_32&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r207": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "33",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_33_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r208": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r209": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "9",
   "IssueDate": "2024-01-01",
   "Paragraph": "7.2.34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=9&code=ifrs-tx-2024-en-r&anchor=para_7.2.34&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r210": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "9",
   "IssueDate": "2024-01-01",
   "Paragraph": "7.2.42",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=9&code=ifrs-tx-2024-en-r&anchor=para_7.2.42&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r211": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "SIC",
   "Number": "29",
   "IssueDate": "2024-01-01",
   "Paragraph": "6A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=SIC&num=29&code=ifrs-tx-2024-en-r&anchor=para_6A&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r212": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "SIC",
   "Number": "29",
   "IssueDate": "2024-01-01",
   "Section": "Consensus",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=SIC&num=29&code=ifrs-tx-2024-en-r&doctype=Standard&dita_xref=SIC29_g6-7_TI",
   "URIDate": "2024-03-27"
  },
  "r213": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Note": "Effective 2025-01-01",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2024-01-01",
   "Paragraph": "A19",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2024-en-r&anchor=para_A19_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r214": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "102",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_102&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r215": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "103",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_103&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r216": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "108",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_108&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r217": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "68",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_68&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r218": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "78",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_78_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r219": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "78",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_78_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r220": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "82A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_82A&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r221": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "IG6",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_IG6&doctype=Implementation%20Guidance",
   "URIDate": "2024-03-27"
  },
  "r222": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "80",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_80_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r223": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "80",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_80_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r224": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "37",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_37_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r225": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "37",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_37_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r226": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "37",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_37_h&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r227": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "142",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_142_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r228": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "142",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_142_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r229": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "142",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_142_h&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r230": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "147",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_147_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r231": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "24",
   "IssueDate": "2024-01-01",
   "Paragraph": "21",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=24&code=ifrs-tx-2024-en-r&anchor=para_21_g&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r232": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "119",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_119_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r233": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "14",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_14_f&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r234": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "16",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_16_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r235": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "17",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_17_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r236": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r237": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "44D",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_44D&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r238": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Section": "A Statement of cash flows for an entity other than a financial institution",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&doctype=Illustrative%20Examples&dita_xref=IAS07_IE_A_TI",
   "URIDate": "2024-03-27"
  },
  "r239": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "B10",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2024-en-r&anchor=para_B10_b&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r240": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "B89",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_B89_a&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r241": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2024-01-01",
   "Paragraph": "B89",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2024-en-r&anchor=para_B89_c&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r242": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2024-01-01",
   "Paragraph": "113",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2024-en-r&anchor=para_113_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r243": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "2",
   "IssueDate": "2024-01-01",
   "Paragraph": "45",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=2&code=ifrs-tx-2024-en-r&anchor=para_45_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r244": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "2",
   "IssueDate": "2024-01-01",
   "Paragraph": "IG23",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=2&code=ifrs-tx-2024-en-r&anchor=para_IG23&doctype=Implementation%20Guidance",
   "URIDate": "2024-03-27"
  },
  "r245": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35M",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35M&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r246": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "35N",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_35N&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r247": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B11",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B11_a&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r248": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B11",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B11&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r249": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B35",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B35_a&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r250": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B35",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B35_d&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r251": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B35",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B35_e&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r252": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B35",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B35_g&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r253": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "B35",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_B35&doctype=Appendix&subtype=B",
   "URIDate": "2024-03-27"
  },
  "r254": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "IG20C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_IG20C&doctype=Implementation%20Guidance",
   "URIDate": "2024-03-27"
  },
  "r255": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "IG20D",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_IG20D&doctype=Implementation%20Guidance",
   "URIDate": "2024-03-27"
  },
  "r256": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "IG31A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_IG31A&doctype=Implementation%20Guidance",
   "URIDate": "2024-03-27"
  },
  "r257": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "23",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_23&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r258": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r259": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12"
  },
  "r260": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "b"
  },
  "r261": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "b-2"
  },
  "r262": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "b-23"
  },
  "r263": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "d1-1"
  },
  "r264": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "g"
  },
  "r265": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12, 13, 15d"
  },
  "r266": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "13e",
   "Subsection": "4c"
  },
  "r267": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "14a",
   "Subsection": "12"
  },
  "r268": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "14d",
   "Subsection": "2b"
  },
  "r269": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "15",
   "Subsection": "d"
  },
  "r270": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 10-K",
   "Number": "249",
   "Section": "310"
  },
  "r271": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 10-Q",
   "Number": "240",
   "Section": "308",
   "Subsection": "a"
  },
  "r272": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Number": "249",
   "Section": "220",
   "Subsection": "f"
  },
  "r273": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16",
   "Subsection": "J",
   "Paragraph": "a"
  },
  "r274": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K"
  },
  "r275": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "b",
   "Paragraph": "1"
  },
  "r276": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "i"
  },
  "r277": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "ii"
  },
  "r278": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "iii"
  },
  "r279": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "b",
   "Paragraph": "2"
  },
  "r280": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "c",
   "Paragraph": "1"
  },
  "r281": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "c",
   "Paragraph": "2"
  },
  "r282": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "i"
  },
  "r283": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "ii"
  },
  "r284": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "16K",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "iii"
  },
  "r285": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1"
  },
  "r286": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i"
  },
  "r287": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "A"
  },
  "r288": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "B"
  },
  "r289": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "C"
  },
  "r290": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "D"
  },
  "r291": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "E"
  },
  "r292": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "ii"
  },
  "r293": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "1",
   "Subparagraph": "iii"
  },
  "r294": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 20-F",
   "Section": "6",
   "Subsection": "F",
   "Paragraph": "2"
  },
  "r295": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Number": "249",
   "Section": "240",
   "Subsection": "f"
  },
  "r296": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a"
  },
  "r297": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1"
  },
  "r298": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "i"
  },
  "r299": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "ii"
  },
  "r300": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "iii"
  },
  "r301": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "iv"
  },
  "r302": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "v"
  },
  "r303": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "2"
  },
  "r304": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "a",
   "Subparagraph": "3"
  },
  "r305": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 40-F",
   "Section": "19",
   "Paragraph": "b"
  },
  "r306": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 6-K",
   "Section": "General Instruction",
   "Subsection": "B"
  },
  "r307": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 8-K",
   "Section": "1.05"
  },
  "r308": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 8-K",
   "Section": "1.05",
   "Subsection": "Instruction",
   "Paragraph": "2"
  },
  "r309": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form 8-K",
   "Section": "1.05",
   "Subsection": "a"
  },
  "r310": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a"
  },
  "r311": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1"
  },
  "r312": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "i"
  },
  "r313": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "ii"
  },
  "r314": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "iii"
  },
  "r315": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "iv"
  },
  "r316": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "1",
   "Sentence": "v"
  },
  "r317": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "2"
  },
  "r318": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "a",
   "Subparagraph": "3"
  },
  "r319": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Form N-CSR",
   "Section": "18",
   "Paragraph": "b"
  },
  "r320": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Forms 10-K, 10-Q, 20-F",
   "Number": "240",
   "Section": "13",
   "Subsection": "a-1"
  },
  "r321": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v"
  },
  "r322": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "1"
  },
  "r323": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "2",
   "Subparagraph": "ii"
  },
  "r324": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "2",
   "Subparagraph": "iii"
  },
  "r325": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "2",
   "Subparagraph": "iv"
  },
  "r326": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "2",
   "Subparagraph": "vi"
  },
  "r327": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "3"
  },
  "r328": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "4"
  },
  "r329": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "5",
   "Subparagraph": "i"
  },
  "r330": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "5",
   "Subparagraph": "ii"
  },
  "r331": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "5",
   "Subparagraph": "iii"
  },
  "r332": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "5",
   "Subparagraph": "iv"
  },
  "r333": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "6"
  },
  "r334": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "v",
   "Paragraph": "6",
   "Subparagraph": "i"
  },
  "r335": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w"
  },
  "r336": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1"
  },
  "r337": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i"
  },
  "r338": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "A"
  },
  "r339": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "B"
  },
  "r340": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "C"
  },
  "r341": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "D"
  },
  "r342": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "i",
   "Sentence": "E"
  },
  "r343": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "ii"
  },
  "r344": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "1",
   "Subparagraph": "iii"
  },
  "r345": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "w",
   "Paragraph": "2"
  },
  "r346": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "1"
  },
  "r347": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2"
  },
  "r348": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2",
   "Subparagraph": "ii",
   "Sentence": "A"
  },
  "r349": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2",
   "Subparagraph": "ii",
   "Sentence": "C"
  },
  "r350": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2",
   "Subparagraph": "ii",
   "Sentence": "D"
  },
  "r351": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2",
   "Subparagraph": "ii",
   "Sentence": "E"
  },
  "r352": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "402",
   "Subsection": "x",
   "Paragraph": "2",
   "Subparagraph": "ii",
   "Sentence": "F"
  },
  "r353": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "a"
  },
  "r354": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "a",
   "Paragraph": "1"
  },
  "r355": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "a",
   "Paragraph": "2",
   "Subparagraph": "A"
  },
  "r356": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "a",
   "Paragraph": "2",
   "Subparagraph": "B"
  },
  "r357": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "a",
   "Paragraph": "2",
   "Subparagraph": "C"
  },
  "r358": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Number": "229",
   "Section": "408",
   "Subsection": "b",
   "Paragraph": "1"
  },
  "r359": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106"
  },
  "r360": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "b",
   "Paragraph": "1"
  },
  "r361": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "i"
  },
  "r362": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "ii"
  },
  "r363": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "b",
   "Paragraph": "1",
   "Subparagraph": "iii"
  },
  "r364": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "b",
   "Paragraph": "2"
  },
  "r365": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "c",
   "Paragraph": "1"
  },
  "r366": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "c",
   "Paragraph": "2"
  },
  "r367": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "i"
  },
  "r368": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "ii"
  },
  "r369": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-K",
   "Section": "106",
   "Subsection": "c",
   "Paragraph": "2",
   "Subparagraph": "iii"
  },
  "r370": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Regulation S-T",
   "Number": "232",
   "Section": "405"
  },
  "r371": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Securities Act",
   "Number": "230",
   "Section": "405"
  },
  "r372": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Securities Act",
   "Number": "230",
   "Section": "425"
  },
  "r373": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Securities Act",
   "Number": "7A",
   "Section": "B",
   "Subsection": "2"
  },
  "r374": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "10",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_10_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r375": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_106_d&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r376": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "108",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_108&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r377": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "112",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_112_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r378": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "117",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_117&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r379": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "55",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_55&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r380": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "78",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_78&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r381": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2024-01-01",
   "Paragraph": "85",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2024-en-r&anchor=para_85&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r382": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "c",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_c_ii&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r383": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81_g_i&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r384": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2024-01-01",
   "Paragraph": "81",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2024-en-r&anchor=para_81&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r385": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "37",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_37&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r386": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2024-01-01",
   "Paragraph": "73",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2024-en-r&anchor=para_73_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r387": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "135",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_135_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r388": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "142",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_142&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r389": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "144",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_144&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r390": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "5",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_5&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r391": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "57",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_57_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r392": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2024-01-01",
   "Paragraph": "9",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2024-en-r&anchor=para_9&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r393": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "118",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_118_e&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r394": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2024-01-01",
   "Paragraph": "119",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2024-en-r&anchor=para_119&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r395": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "14",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_14&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r396": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "16",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_16&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r397": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20_a&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r398": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20_b&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r399": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20_c&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r400": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r401": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "45",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2024-en-r&anchor=para_45&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r402": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "39",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_39&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r403": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2024-01-01",
   "Paragraph": "7",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2024-en-r&anchor=para_7&doctype=Standard",
   "URIDate": "2024-03-27"
  },
  "r404": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2024-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2024-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2024-03-27"
  }
 }
}
