<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.25.4</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>464</ContextCount>
  <ElementCount>605</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>false</FootnotesReported>
  <SegmentCount>147</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>10</UnitCount>
  <MyReports>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>0000001 - Document - Cover Page</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/CoverPage</Role>
      <ShortName>Cover Page</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>0000002 - Document - Audit Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/AuditInformation</Role>
      <ShortName>Audit Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>9952151 - Statement - Consolidated Balance Sheets</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedBalanceSheets</Role>
      <ShortName>Consolidated Balance Sheets</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R4.htm</HtmlFileName>
      <LongName>9952152 - Statement - Consolidated Balance Sheets (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedBalanceSheetsParenthetical</Role>
      <ShortName>Consolidated Balance Sheets (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R5.htm</HtmlFileName>
      <LongName>9952153 - Statement - Consolidated Statements of Operations</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedStatementsofOperations</Role>
      <ShortName>Consolidated Statements of Operations</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>5</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R6.htm</HtmlFileName>
      <LongName>9952154 - Statement - Consolidated Statements of Comprehensive Income (Loss)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedStatementsofComprehensiveIncomeLoss</Role>
      <ShortName>Consolidated Statements of Comprehensive Income (Loss)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>6</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R7.htm</HtmlFileName>
      <LongName>9952155 - Statement - Consolidated Statements of Cash Flows</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedStatementsofCashFlows</Role>
      <ShortName>Consolidated Statements of Cash Flows</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>7</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R8.htm</HtmlFileName>
      <LongName>9952156 - Statement - Consolidated Statements of Equity</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedStatementsofEquity</Role>
      <ShortName>Consolidated Statements of Equity</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>8</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R9.htm</HtmlFileName>
      <LongName>9952157 - Statement - Consolidated Statements of Equity (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ConsolidatedStatementsofEquityParenthetical</Role>
      <ShortName>Consolidated Statements of Equity (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>9</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R10.htm</HtmlFileName>
      <LongName>9952158 - Disclosure - DESCRIPTION OF BUSINESS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DESCRIPTIONOFBUSINESS</Role>
      <ShortName>DESCRIPTION OF BUSINESS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>10</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R11.htm</HtmlFileName>
      <LongName>9952159 - Disclosure - BASIS OF PRESENTATION AND ACCOUNTING POLICIES</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/BASISOFPRESENTATIONANDACCOUNTINGPOLICIES</Role>
      <ShortName>BASIS OF PRESENTATION AND ACCOUNTING POLICIES</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>11</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R12.htm</HtmlFileName>
      <LongName>9952160 - Disclosure - NEW ACCOUNTING PRONOUNCEMENTS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/NEWACCOUNTINGPRONOUNCEMENTS</Role>
      <ShortName>NEW ACCOUNTING PRONOUNCEMENTS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>12</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R13.htm</HtmlFileName>
      <LongName>9952161 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTS</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>13</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R14.htm</HtmlFileName>
      <LongName>9952162 - Disclosure - SEGMENT INFORMATION</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SEGMENTINFORMATION</Role>
      <ShortName>SEGMENT INFORMATION</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>14</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R15.htm</HtmlFileName>
      <LongName>9952163 - Disclosure - ACQUISITIONS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONS</Role>
      <ShortName>ACQUISITIONS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>15</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R16.htm</HtmlFileName>
      <LongName>9952164 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETS</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>16</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R17.htm</HtmlFileName>
      <LongName>9952165 - Disclosure - INVESTMENTS IN AFFILIATES AND OTHER ENTITIES</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INVESTMENTSINAFFILIATESANDOTHERENTITIES</Role>
      <ShortName>INVESTMENTS IN AFFILIATES AND OTHER ENTITIES</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>17</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R18.htm</HtmlFileName>
      <LongName>9952166 - Disclosure - PER SHARE INFORMATION</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/PERSHAREINFORMATION</Role>
      <ShortName>PER SHARE INFORMATION</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>18</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R19.htm</HtmlFileName>
      <LongName>9952167 - Disclosure - DEBT OBLIGATIONS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONS</Role>
      <ShortName>DEBT OBLIGATIONS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>19</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R20.htm</HtmlFileName>
      <LongName>9952168 - Disclosure - LEASES</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASES</Role>
      <ShortName>LEASES</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>20</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R21.htm</HtmlFileName>
      <LongName>9952169 - Disclosure - INCOME TAXES</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXES</Role>
      <ShortName>INCOME TAXES</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>21</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R22.htm</HtmlFileName>
      <LongName>9952170 - Disclosure - EQUITY</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EQUITY</Role>
      <ShortName>EQUITY</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>22</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R23.htm</HtmlFileName>
      <LongName>9952171 - Disclosure - STOCK-BASED COMPENSATION</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATION</Role>
      <ShortName>STOCK-BASED COMPENSATION</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>23</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R24.htm</HtmlFileName>
      <LongName>9952172 - Disclosure - EMPLOYEE BENEFIT PLANS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EMPLOYEEBENEFITPLANS</Role>
      <ShortName>EMPLOYEE BENEFIT PLANS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>24</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R25.htm</HtmlFileName>
      <LongName>9952173 - Disclosure - COMMITMENTS AND CONTINGENCIES</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/COMMITMENTSANDCONTINGENCIES</Role>
      <ShortName>COMMITMENTS AND CONTINGENCIES</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>25</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R26.htm</HtmlFileName>
      <LongName>9952174 - Disclosure - DETAIL OF CERTAIN ACCOUNTS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTS</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>26</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R27.htm</HtmlFileName>
      <LongName>9952175 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATION</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>27</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R28.htm</HtmlFileName>
      <LongName>995445 - Disclosure - Insider Trading Arrangements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/InsiderTradingArrangements</Role>
      <ShortName>Insider Trading Arrangements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>28</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R29.htm</HtmlFileName>
      <LongName>995447 - Disclosure - Insider Trading Policies and Procedures</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/InsiderTradingPoliciesProc</Role>
      <ShortName>Insider Trading Policies and Procedures</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>29</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R30.htm</HtmlFileName>
      <LongName>995550 - Disclosure - Cybersecurity Risk Management and Strategy Disclosure</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/cyd/role/CybersecurityRiskManagementAndStrategyDisclosure</Role>
      <ShortName>Cybersecurity Risk Management and Strategy Disclosure</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>30</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R31.htm</HtmlFileName>
      <LongName>9955511 - Disclosure - BASIS OF PRESENTATION AND ACCOUNTING POLICIES (Policies)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/BASISOFPRESENTATIONANDACCOUNTINGPOLICIESPolicies</Role>
      <ShortName>BASIS OF PRESENTATION AND ACCOUNTING POLICIES (Policies)</ShortName>
      <MenuCategory>Policies</MenuCategory>
      <Position>31</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R32.htm</HtmlFileName>
      <LongName>9955512 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSTables</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTS</ParentRole>
      <Position>32</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R33.htm</HtmlFileName>
      <LongName>9955513 - Disclosure - SEGMENT INFORMATION (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SEGMENTINFORMATIONTables</Role>
      <ShortName>SEGMENT INFORMATION (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/SEGMENTINFORMATION</ParentRole>
      <Position>33</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R34.htm</HtmlFileName>
      <LongName>9955514 - Disclosure - ACQUISITIONS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSTables</Role>
      <ShortName>ACQUISITIONS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/ACQUISITIONS</ParentRole>
      <Position>34</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R35.htm</HtmlFileName>
      <LongName>9955515 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETSTables</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETS</ParentRole>
      <Position>35</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R36.htm</HtmlFileName>
      <LongName>9955516 - Disclosure - INVESTMENTS IN AFFILIATES AND OTHER ENTITIES (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INVESTMENTSINAFFILIATESANDOTHERENTITIESTables</Role>
      <ShortName>INVESTMENTS IN AFFILIATES AND OTHER ENTITIES (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/INVESTMENTSINAFFILIATESANDOTHERENTITIES</ParentRole>
      <Position>36</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R37.htm</HtmlFileName>
      <LongName>9955517 - Disclosure - PER SHARE INFORMATION (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/PERSHAREINFORMATIONTables</Role>
      <ShortName>PER SHARE INFORMATION (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/PERSHAREINFORMATION</ParentRole>
      <Position>37</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R38.htm</HtmlFileName>
      <LongName>9955518 - Disclosure - DEBT OBLIGATIONS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSTables</Role>
      <ShortName>DEBT OBLIGATIONS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/DEBTOBLIGATIONS</ParentRole>
      <Position>38</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R39.htm</HtmlFileName>
      <LongName>9955519 - Disclosure - LEASES (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESTables</Role>
      <ShortName>LEASES (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/LEASES</ParentRole>
      <Position>39</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R40.htm</HtmlFileName>
      <LongName>9955520 - Disclosure - INCOME TAXES (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESTables</Role>
      <ShortName>INCOME TAXES (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/INCOMETAXES</ParentRole>
      <Position>40</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R41.htm</HtmlFileName>
      <LongName>9955521 - Disclosure - EQUITY (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EQUITYTables</Role>
      <ShortName>EQUITY (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/EQUITY</ParentRole>
      <Position>41</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R42.htm</HtmlFileName>
      <LongName>9955522 - Disclosure - STOCK-BASED COMPENSATION (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONTables</Role>
      <ShortName>STOCK-BASED COMPENSATION (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/STOCKBASEDCOMPENSATION</ParentRole>
      <Position>42</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R43.htm</HtmlFileName>
      <LongName>9955523 - Disclosure - EMPLOYEE BENEFIT PLANS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EMPLOYEEBENEFITPLANSTables</Role>
      <ShortName>EMPLOYEE BENEFIT PLANS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/EMPLOYEEBENEFITPLANS</ParentRole>
      <Position>43</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R44.htm</HtmlFileName>
      <LongName>9955524 - Disclosure - DETAIL OF CERTAIN ACCOUNTS (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSTables</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTS</ParentRole>
      <Position>44</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R45.htm</HtmlFileName>
      <LongName>9955525 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATIONTables</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATION</ParentRole>
      <Position>45</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R46.htm</HtmlFileName>
      <LongName>9955526 - Disclosure - BASIS OF PRESENTATION AND ACCOUNTING POLICIES - Stock-Based Compensation (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/BASISOFPRESENTATIONANDACCOUNTINGPOLICIESStockBasedCompensationDetails</Role>
      <ShortName>BASIS OF PRESENTATION AND ACCOUNTING POLICIES - Stock-Based Compensation (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>46</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R47.htm</HtmlFileName>
      <LongName>9955527 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Performance Obligation (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSPerformanceObligationDetails</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Performance Obligation (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>47</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R48.htm</HtmlFileName>
      <LongName>9955528 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSAdditionalInformationDetails</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>48</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R49.htm</HtmlFileName>
      <LongName>9955529 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Revenue Disaggregated by Geographic Location and Contract Type (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSRevenueDisaggregatedbyGeographicLocationandContractTypeDetails</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Revenue Disaggregated by Geographic Location and Contract Type (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>49</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R50.htm</HtmlFileName>
      <LongName>9955530 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Contract Assets and Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSContractAssetsandLiabilitiesDetails</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Contract Assets and Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>50</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R51.htm</HtmlFileName>
      <LongName>9955531 - Disclosure - REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Composition of the Allowance for Credit Losses (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/REVENUERECOGNITIONANDRELATEDBALANCESHEETACCOUNTSCompositionoftheAllowanceforCreditLossesDetails</Role>
      <ShortName>REVENUE RECOGNITION AND RELATED BALANCE SHEET ACCOUNTS - Composition of the Allowance for Credit Losses (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>51</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R52.htm</HtmlFileName>
      <LongName>9955532 - Disclosure - SEGMENT INFORMATION - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SEGMENTINFORMATIONNarrativeDetails</Role>
      <ShortName>SEGMENT INFORMATION - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>52</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R53.htm</HtmlFileName>
      <LongName>9955533 - Disclosure - SEGMENT INFORMATION - Summarized Financial Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SEGMENTINFORMATIONSummarizedFinancialInformationDetails</Role>
      <ShortName>SEGMENT INFORMATION - Summarized Financial Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>53</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R54.htm</HtmlFileName>
      <LongName>9955534 - Disclosure - ACQUISITIONS - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSAdditionalInformationDetails</Role>
      <ShortName>ACQUISITIONS - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>54</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R55.htm</HtmlFileName>
      <LongName>9955535 - Disclosure - ACQUISITIONS - Aggregate Consideration Paid or Payable and Allocation of Net Assets (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSAggregateConsiderationPaidorPayableandAllocationofNetAssetsDetails</Role>
      <ShortName>ACQUISITIONS - Aggregate Consideration Paid or Payable and Allocation of Net Assets (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>55</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R56.htm</HtmlFileName>
      <LongName>9955536 - Disclosure - ACQUISITIONS - Estimated Fair Values of Identifiable Intangible Assets and Related Weighted Average Amortization (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSEstimatedFairValuesofIdentifiableIntangibleAssetsandRelatedWeightedAverageAmortizationDetails</Role>
      <ShortName>ACQUISITIONS - Estimated Fair Values of Identifiable Intangible Assets and Related Weighted Average Amortization (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>56</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R57.htm</HtmlFileName>
      <LongName>9955537 - Disclosure - ACQUISITIONS - Significant Estimates Used by Management in Determining Fair Values of Customer Relationships Acquired (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSSignificantEstimatesUsedbyManagementinDeterminingFairValuesofCustomerRelationshipsAcquiredDetails</Role>
      <ShortName>ACQUISITIONS - Significant Estimates Used by Management in Determining Fair Values of Customer Relationships Acquired (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>57</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R58.htm</HtmlFileName>
      <LongName>9955538 - Disclosure - ACQUISITIONS - Aggregate Fair Values of Outstanding Contingent Consideration Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSAggregateFairValuesofOutstandingContingentConsiderationLiabilitiesDetails</Role>
      <ShortName>ACQUISITIONS - Aggregate Fair Values of Outstanding Contingent Consideration Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>58</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R59.htm</HtmlFileName>
      <LongName>9955539 - Disclosure - ACQUISITIONS - Unaudited Supplemental Pro Forma Results of Operations (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSUnauditedSupplementalProFormaResultsofOperationsDetails</Role>
      <ShortName>ACQUISITIONS - Unaudited Supplemental Pro Forma Results of Operations (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>59</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R60.htm</HtmlFileName>
      <LongName>9955540 - Disclosure - ACQUISITIONS - Income From Acquisitions By Year (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/ACQUISITIONSIncomeFromAcquisitionsByYearDetails</Role>
      <ShortName>ACQUISITIONS - Income From Acquisitions By Year (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>60</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R61.htm</HtmlFileName>
      <LongName>9955541 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS - Summary of Changes in Goodwill (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETSSummaryofChangesinGoodwillDetails</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS - Summary of Changes in Goodwill (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>61</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R62.htm</HtmlFileName>
      <LongName>9955542 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS - Other Intangible Assets (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETSOtherIntangibleAssetsDetails</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS - Other Intangible Assets (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>62</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R63.htm</HtmlFileName>
      <LongName>9955543 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETSAdditionalInformationDetails</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>63</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R64.htm</HtmlFileName>
      <LongName>9955544 - Disclosure - GOODWILL AND OTHER INTANGIBLE ASSETS - Estimated Future Aggregate Amortization Expense of Intangible Assets (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/GOODWILLANDOTHERINTANGIBLEASSETSEstimatedFutureAggregateAmortizationExpenseofIntangibleAssetsDetails</Role>
      <ShortName>GOODWILL AND OTHER INTANGIBLE ASSETS - Estimated Future Aggregate Amortization Expense of Intangible Assets (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>64</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R65.htm</HtmlFileName>
      <LongName>9955545 - Disclosure - INVESTMENTS IN AFFILIATES AND OTHER ENTITIES - Equity Investments by Type (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INVESTMENTSINAFFILIATESANDOTHERENTITIESEquityInvestmentsbyTypeDetails</Role>
      <ShortName>INVESTMENTS IN AFFILIATES AND OTHER ENTITIES - Equity Investments by Type (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>65</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R66.htm</HtmlFileName>
      <LongName>9955546 - Disclosure - INVESTMENTS IN AFFILIATES AND OTHER ENTITIES - Equity Method Investments (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INVESTMENTSINAFFILIATESANDOTHERENTITIESEquityMethodInvestmentsDetails</Role>
      <ShortName>INVESTMENTS IN AFFILIATES AND OTHER ENTITIES - Equity Method Investments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>66</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R67.htm</HtmlFileName>
      <LongName>9955547 - Disclosure - PER SHARE INFORMATION - Basic and Diluted Earnings Per Share (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/PERSHAREINFORMATIONBasicandDilutedEarningsPerShareDetails</Role>
      <ShortName>PER SHARE INFORMATION - Basic and Diluted Earnings Per Share (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>67</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R68.htm</HtmlFileName>
      <LongName>9955548 - Disclosure - DEBT OBLIGATIONS - Long-term Debt Obligations (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSLongtermDebtObligationsDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Long-term Debt Obligations (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>68</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R69.htm</HtmlFileName>
      <LongName>9955549 - Disclosure - DEBT OBLIGATIONS - Principal Payments Required to be Made (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSPrincipalPaymentsRequiredtobeMadeDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Principal Payments Required to be Made (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>69</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R70.htm</HtmlFileName>
      <LongName>9955550 - Disclosure - DEBT OBLIGATIONS - Senior Notes (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSSeniorNotesDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Senior Notes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>70</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R71.htm</HtmlFileName>
      <LongName>9955551 - Disclosure - DEBT OBLIGATIONS - Interest on Senior Notes (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSInterestonSeniorNotesDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Interest on Senior Notes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>71</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R72.htm</HtmlFileName>
      <LongName>9955552 - Disclosure - DEBT OBLIGATIONS - Senior Credit Facility (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSSeniorCreditFacilityDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Senior Credit Facility (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>72</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R73.htm</HtmlFileName>
      <LongName>9955553 - Disclosure - DEBT OBLIGATIONS - Information on Borrowings under Current and Prior Credit Facility and Commercial Paper Program (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSInformationonBorrowingsunderCurrentandPriorCreditFacilityandCommercialPaperProgramDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Information on Borrowings under Current and Prior Credit Facility and Commercial Paper Program (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>73</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R74.htm</HtmlFileName>
      <LongName>9955554 - Disclosure - DEBT OBLIGATIONS - Commercial Paper Program (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSCommercialPaperProgramDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Commercial Paper Program (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>74</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R75.htm</HtmlFileName>
      <LongName>9955555 - Disclosure - DEBT OBLIGATIONS - Letters of Credit Outside the Credit Facility (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DEBTOBLIGATIONSLettersofCreditOutsidetheCreditFacilityDetails</Role>
      <ShortName>DEBT OBLIGATIONS - Letters of Credit Outside the Credit Facility (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>75</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R76.htm</HtmlFileName>
      <LongName>9955556 - Disclosure - LEASES - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESNarrativeDetails</Role>
      <ShortName>LEASES - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>76</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R77.htm</HtmlFileName>
      <LongName>9955557 - Disclosure - LEASES - Components of Lease Costs (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESComponentsofLeaseCostsDetails</Role>
      <ShortName>LEASES - Components of Lease Costs (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>77</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R78.htm</HtmlFileName>
      <LongName>9955558 - Disclosure - LEASES - Components of Leases in the Balance Sheet (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESComponentsofLeasesintheBalanceSheetDetails</Role>
      <ShortName>LEASES - Components of Leases in the Balance Sheet (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>78</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R79.htm</HtmlFileName>
      <LongName>9955559 - Disclosure - LEASES - Future Minimum Lease Payments (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESFutureMinimumLeasePaymentsDetails</Role>
      <ShortName>LEASES - Future Minimum Lease Payments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>79</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R80.htm</HtmlFileName>
      <LongName>9955560 - Disclosure - LEASES - Weighted Average Remaining Lease Terms and Discount Rates (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/LEASESWeightedAverageRemainingLeaseTermsandDiscountRatesDetails</Role>
      <ShortName>LEASES - Weighted Average Remaining Lease Terms and Discount Rates (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>80</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R81.htm</HtmlFileName>
      <LongName>9955561 - Disclosure - INCOME TAXES - Components of Income (Loss) Before Income Taxes (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESComponentsofIncomeLossBeforeIncomeTaxesDetails</Role>
      <ShortName>INCOME TAXES - Components of Income (Loss) Before Income Taxes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>81</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R82.htm</HtmlFileName>
      <LongName>9955562 - Disclosure - INCOME TAXES - Provision for Income Taxes (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESProvisionforIncomeTaxesDetails</Role>
      <ShortName>INCOME TAXES - Provision for Income Taxes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>82</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R83.htm</HtmlFileName>
      <LongName>9955563 - Disclosure - INCOME TAXES - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESNarrativeDetails</Role>
      <ShortName>INCOME TAXES - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>83</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R84.htm</HtmlFileName>
      <LongName>9955564 - Disclosure - INCOME TAXES - Effective Income Tax Rate Reconciliation (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESEffectiveIncomeTaxRateReconciliationDetails</Role>
      <ShortName>INCOME TAXES - Effective Income Tax Rate Reconciliation (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>84</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R85.htm</HtmlFileName>
      <LongName>9955565 - Disclosure - INCOME TAXES - Deferred Tax Assets and Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESDeferredTaxAssetsandLiabilitiesDetails</Role>
      <ShortName>INCOME TAXES - Deferred Tax Assets and Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>85</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R86.htm</HtmlFileName>
      <LongName>9955566 - Disclosure - INCOME TAXES - Net Deferred Income Tax Assets and Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESNetDeferredIncomeTaxAssetsandLiabilitiesDetails</Role>
      <ShortName>INCOME TAXES - Net Deferred Income Tax Assets and Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>86</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R87.htm</HtmlFileName>
      <LongName>9955567 - Disclosure - INCOME TAXES - Reconciliation of Unrecognized Tax Benefit (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESReconciliationofUnrecognizedTaxBenefitDetails</Role>
      <ShortName>INCOME TAXES - Reconciliation of Unrecognized Tax Benefit (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>87</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R88.htm</HtmlFileName>
      <LongName>9955568 - Disclosure - INCOME TAXES - Balances of Unrecognized Tax Benefits (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/INCOMETAXESBalancesofUnrecognizedTaxBenefitsDetails</Role>
      <ShortName>INCOME TAXES - Balances of Unrecognized Tax Benefits (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>88</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R89.htm</HtmlFileName>
      <LongName>9955569 - Disclosure - EQUITY - Treasury Stock (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EQUITYTreasuryStockDetails</Role>
      <ShortName>EQUITY - Treasury Stock (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>89</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R90.htm</HtmlFileName>
      <LongName>9955570 - Disclosure - EQUITY - Repurchases of Common Stock Under Stock Repurchase Programs (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EQUITYRepurchasesofCommonStockUnderStockRepurchaseProgramsDetails</Role>
      <ShortName>EQUITY - Repurchases of Common Stock Under Stock Repurchase Programs (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>90</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R91.htm</HtmlFileName>
      <LongName>9955571 - Disclosure - EQUITY - Dividends (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EQUITYDividendsDetails</Role>
      <ShortName>EQUITY - Dividends (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>91</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R92.htm</HtmlFileName>
      <LongName>9955572 - Disclosure - STOCK-BASED COMPENSATION - Stock Incentive Plans (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONStockIncentivePlansDetails</Role>
      <ShortName>STOCK-BASED COMPENSATION - Stock Incentive Plans (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>92</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R93.htm</HtmlFileName>
      <LongName>9955573 - Disclosure - STOCK-BASED COMPENSATION - Summary of RSUs and PSUs to be Settled in Common Stock Activity (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONSummaryofRSUsandPSUstobeSettledinCommonStockActivityDetails</Role>
      <ShortName>STOCK-BASED COMPENSATION - Summary of RSUs and PSUs to be Settled in Common Stock Activity (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>93</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R94.htm</HtmlFileName>
      <LongName>9955574 - Disclosure - STOCK-BASED COMPENSATION - PSUs to be Settled in Common Stock - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONPSUstobeSettledinCommonStockNarrativeDetails</Role>
      <ShortName>STOCK-BASED COMPENSATION - PSUs to be Settled in Common Stock - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>94</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R95.htm</HtmlFileName>
      <LongName>9955575 - Disclosure - STOCK-BASED COMPENSATION - Grant Date Fair Value for Awards of Performance Units Inputs (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONGrantDateFairValueforAwardsofPerformanceUnitsInputsDetails</Role>
      <ShortName>STOCK-BASED COMPENSATION - Grant Date Fair Value for Awards of Performance Units Inputs (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>95</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R96.htm</HtmlFileName>
      <LongName>9955576 - Disclosure - STOCK-BASED COMPENSATION - Restricted Stock and RSUs to be Settled in Common Stock (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/STOCKBASEDCOMPENSATIONRestrictedStockandRSUstobeSettledinCommonStockDetails</Role>
      <ShortName>STOCK-BASED COMPENSATION - Restricted Stock and RSUs to be Settled in Common Stock (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>96</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R97.htm</HtmlFileName>
      <LongName>9955577 - Disclosure - EMPLOYEE BENEFIT PLANS - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EMPLOYEEBENEFITPLANSAdditionalInformationDetails</Role>
      <ShortName>EMPLOYEE BENEFIT PLANS - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>97</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R98.htm</HtmlFileName>
      <LongName>9955578 - Disclosure - EMPLOYEE BENEFIT PLANS - Summary of Plan Information Relating to Participation in Multiemployer Pension Plans (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EMPLOYEEBENEFITPLANSSummaryofPlanInformationRelatingtoParticipationinMultiemployerPensionPlansDetails</Role>
      <ShortName>EMPLOYEE BENEFIT PLANS - Summary of Plan Information Relating to Participation in Multiemployer Pension Plans (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>98</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R99.htm</HtmlFileName>
      <LongName>9955579 - Disclosure - EMPLOYEE BENEFIT PLANS - Changes in FMV of COLI Assets and Deferred Compensation Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/EMPLOYEEBENEFITPLANSChangesinFMVofCOLIAssetsandDeferredCompensationLiabilitiesDetails</Role>
      <ShortName>EMPLOYEE BENEFIT PLANS - Changes in FMV of COLI Assets and Deferred Compensation Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>99</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R100.htm</HtmlFileName>
      <LongName>9955580 - Disclosure - COMMITMENTS AND CONTINGENCIES - Silverado Wildfire Matter (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/COMMITMENTSANDCONTINGENCIESSilveradoWildfireMatterDetails</Role>
      <ShortName>COMMITMENTS AND CONTINGENCIES - Silverado Wildfire Matter (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>100</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R101.htm</HtmlFileName>
      <LongName>9955581 - Disclosure - COMMITMENTS AND CONTINGENCIES - Insurance (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/COMMITMENTSANDCONTINGENCIESInsuranceDetails</Role>
      <ShortName>COMMITMENTS AND CONTINGENCIES - Insurance (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>101</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R102.htm</HtmlFileName>
      <LongName>9955582 - Disclosure - COMMITMENTS AND CONTINGENCIES - Performance Bonds and Parent Guarantees (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/COMMITMENTSANDCONTINGENCIESPerformanceBondsandParentGuaranteesDetails</Role>
      <ShortName>COMMITMENTS AND CONTINGENCIES - Performance Bonds and Parent Guarantees (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>102</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R103.htm</HtmlFileName>
      <LongName>9955583 - Disclosure - COMMITMENTS AND CONTINGENCIES - Committed Expenditures (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/COMMITMENTSANDCONTINGENCIESCommittedExpendituresDetails</Role>
      <ShortName>COMMITMENTS AND CONTINGENCIES - Committed Expenditures (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>103</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R104.htm</HtmlFileName>
      <LongName>9955584 - Disclosure - DETAIL OF CERTAIN ACCOUNTS - Cash and Cash Equivalents (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSCashandCashEquivalentsDetails</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS - Cash and Cash Equivalents (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>104</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R105.htm</HtmlFileName>
      <LongName>9955585 - Disclosure - DETAIL OF CERTAIN ACCOUNTS - Schedule of Inventory (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSScheduleofInventoryDetails</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS - Schedule of Inventory (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>105</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R106.htm</HtmlFileName>
      <LongName>9955586 - Disclosure - DETAIL OF CERTAIN ACCOUNTS - Prepaid Expenses (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSPrepaidExpensesDetails</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS - Prepaid Expenses (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>106</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R107.htm</HtmlFileName>
      <LongName>9955587 - Disclosure - DETAIL OF CERTAIN ACCOUNTS - Property and Equipment (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSPropertyandEquipmentDetails</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS - Property and Equipment (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>107</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R108.htm</HtmlFileName>
      <LongName>9955588 - Disclosure - DETAIL OF CERTAIN ACCOUNTS - Accounts Payable and Accrued Expenses (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/DETAILOFCERTAINACCOUNTSAccountsPayableandAccruedExpensesDetails</Role>
      <ShortName>DETAIL OF CERTAIN ACCOUNTS - Accounts Payable and Accrued Expenses (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>108</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R109.htm</HtmlFileName>
      <LongName>9955589 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION - Reconciliation of Cash, Cash Equivalents, and Restricted Cash (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATIONReconciliationofCashCashEquivalentsandRestrictedCashDetails</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION - Reconciliation of Cash, Cash Equivalents, and Restricted Cash (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>109</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R110.htm</HtmlFileName>
      <LongName>9955590 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION - Supplemental Cash Flow Information Related to Leases (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATIONSupplementalCashFlowInformationRelatedtoLeasesDetails</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION - Supplemental Cash Flow Information Related to Leases (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>110</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R111.htm</HtmlFileName>
      <LongName>9955591 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION - Additional Supplemental Cash Flow Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATIONAdditionalSupplementalCashFlowInformationDetails</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION - Additional Supplemental Cash Flow Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>111</Position>
    </Report>
    <Report instance="pwr-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R112.htm</HtmlFileName>
      <LongName>9955592 - Disclosure - SUPPLEMENTAL CASH FLOW INFORMATION - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://quantaservices.com/role/SUPPLEMENTALCASHFLOWINFORMATIONNarrativeDetails</Role>
      <ShortName>SUPPLEMENTAL CASH FLOW INFORMATION - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>112</Position>
    </Report>
    <Report>
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <LongName>All Reports</LongName>
      <ReportType>Book</ReportType>
      <ShortName>All Reports</ShortName>
    </Report>
  </MyReports>
  <InputFiles>
    <File doctype="10-K" isDefinitelyFs="true" isUsgaap="true" original="pwr-20251231.htm">pwr-20251231.htm</File>
    <File>pwr-20251231.xsd</File>
    <File>pwr-20251231_cal.xml</File>
    <File>pwr-20251231_def.xml</File>
    <File>pwr-20251231_lab.xml</File>
    <File>pwr-20251231_pre.xml</File>
  </InputFiles>
  <SupplementalFiles>
    <File>pwr-20251231_g1.jpg</File>
    <File>pwr-20251231_g2.jpg</File>
  </SupplementalFiles>
  <BaseTaxonomies>
    <BaseTaxonomy items="1">http://fasb.org/srt/2025</BaseTaxonomy>
    <BaseTaxonomy items="1562">http://fasb.org/us-gaap/2025</BaseTaxonomy>
    <BaseTaxonomy items="15">http://xbrl.sec.gov/cyd/2025</BaseTaxonomy>
    <BaseTaxonomy items="38">http://xbrl.sec.gov/dei/2025</BaseTaxonomy>
    <BaseTaxonomy items="5">http://xbrl.sec.gov/ecd/2025</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>true</HasCalculationLinkbase>
</FilingSummary>
