<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.25.4</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>206</ContextCount>
  <ElementCount>497</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>false</FootnotesReported>
  <SegmentCount>77</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>14</UnitCount>
  <MyReports>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>0000001 - Document - Cover Page</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CoverPage</Role>
      <ShortName>Cover Page</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>0000002 - Document - Audit Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/AuditInformation</Role>
      <ShortName>Audit Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>9952151 - Statement - CONSOLIDATED BALANCE SHEETS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CONSOLIDATEDBALANCESHEETS</Role>
      <ShortName>CONSOLIDATED BALANCE SHEETS</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="cstl-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://www.castlebiosciences.com/role/CONSOLIDATEDBALANCESHEETSParenthetical</Role>
      <ShortName>CONSOLIDATED BALANCE SHEETS (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report instance="cstl-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://www.castlebiosciences.com/role/CONSOLIDATEDSTATEMENTSOFOPERATIONS</Role>
      <ShortName>CONSOLIDATED STATEMENTS OF OPERATIONS</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>5</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R6.htm</HtmlFileName>
      <LongName>9952154 - Statement - CONSOLIDATED STATEMENTS OF COMPREHENSIVE (LOSS) INCOME</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVELOSSINCOME</Role>
      <ShortName>CONSOLIDATED STATEMENTS OF COMPREHENSIVE (LOSS) INCOME</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>6</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R7.htm</HtmlFileName>
      <LongName>9952155 - Statement - CONSOLIDATED STATEMENTS STOCKHOLDERS??? EQUITY</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CONSOLIDATEDSTATEMENTSSTOCKHOLDERSEQUITY</Role>
      <ShortName>CONSOLIDATED STATEMENTS STOCKHOLDERS??? EQUITY</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>7</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R8.htm</HtmlFileName>
      <LongName>9952156 - Statement - CONSOLIDATED STATEMENTS OF CASH FLOWS</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CONSOLIDATEDSTATEMENTSOFCASHFLOWS</Role>
      <ShortName>CONSOLIDATED STATEMENTS OF CASH FLOWS</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>8</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R9.htm</HtmlFileName>
      <LongName>9952157 - Disclosure - Organization and Description of Business</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/OrganizationandDescriptionofBusiness</Role>
      <ShortName>Organization and Description of Business</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>9</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R10.htm</HtmlFileName>
      <LongName>9952158 - Disclosure - Summary of Significant Accounting Policies</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SummaryofSignificantAccountingPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>10</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R11.htm</HtmlFileName>
      <LongName>9952159 - Disclosure - Revenue</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/Revenue</Role>
      <ShortName>Revenue</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>11</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R12.htm</HtmlFileName>
      <LongName>9952160 - Disclosure - (Loss) Earnings Per Share</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LossEarningsPerShare</Role>
      <ShortName>(Loss) Earnings Per Share</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>12</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R13.htm</HtmlFileName>
      <LongName>9952161 - Disclosure - Marketable Investment Securities</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecurities</Role>
      <ShortName>Marketable Investment Securities</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>13</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R14.htm</HtmlFileName>
      <LongName>9952162 - Disclosure - Property and Equipment, Net</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/PropertyandEquipmentNet</Role>
      <ShortName>Property and Equipment, Net</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>14</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R15.htm</HtmlFileName>
      <LongName>9952163 - Disclosure - Goodwill and Other Intangible Assets, Net</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNet</Role>
      <ShortName>Goodwill and Other Intangible Assets, Net</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>15</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R16.htm</HtmlFileName>
      <LongName>9952164 - Disclosure - Other Accrued and Current Liabilities</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/OtherAccruedandCurrentLiabilities</Role>
      <ShortName>Other Accrued and Current Liabilities</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>16</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R17.htm</HtmlFileName>
      <LongName>9952165 - Disclosure - Long-Term Debt</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebt</Role>
      <ShortName>Long-Term Debt</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>17</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R18.htm</HtmlFileName>
      <LongName>9952166 - Disclosure - Leases</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/Leases</Role>
      <ShortName>Leases</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>18</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R19.htm</HtmlFileName>
      <LongName>9952167 - Disclosure - Fair Value Measurements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/FairValueMeasurements</Role>
      <ShortName>Fair Value Measurements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>19</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R20.htm</HtmlFileName>
      <LongName>9952168 - Disclosure - Commitments and Contingencies</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CommitmentsandContingencies</Role>
      <ShortName>Commitments and Contingencies</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>20</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R21.htm</HtmlFileName>
      <LongName>9952169 - Disclosure - Stockholders??? Equity</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockholdersEquity</Role>
      <ShortName>Stockholders??? Equity</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>21</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R22.htm</HtmlFileName>
      <LongName>9952170 - Disclosure - Stock Incentive Plans and Stock Based Compensation</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensation</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>22</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R23.htm</HtmlFileName>
      <LongName>9952171 - Disclosure - Income Taxes</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxes</Role>
      <ShortName>Income Taxes</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>23</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R24.htm</HtmlFileName>
      <LongName>9952172 - Disclosure - Segment and Related Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SegmentandRelatedInformation</Role>
      <ShortName>Segment and Related Information</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>24</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R25.htm</HtmlFileName>
      <LongName>9952173 - Disclosure - Subsequent Events</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SubsequentEvents</Role>
      <ShortName>Subsequent Events</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>25</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R26.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>26</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R27.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>27</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R28.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>28</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R29.htm</HtmlFileName>
      <LongName>9955511 - Disclosure - Summary of Significant Accounting Policies (Policies)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SummaryofSignificantAccountingPoliciesPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies (Policies)</ShortName>
      <MenuCategory>Policies</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/SummaryofSignificantAccountingPolicies</ParentRole>
      <Position>29</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R30.htm</HtmlFileName>
      <LongName>9955512 - Disclosure - Revenue (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/RevenueTables</Role>
      <ShortName>Revenue (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/Revenue</ParentRole>
      <Position>30</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R31.htm</HtmlFileName>
      <LongName>9955513 - Disclosure - (Loss) Earnings Per Share (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LossEarningsPerShareTables</Role>
      <ShortName>(Loss) Earnings Per Share (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/LossEarningsPerShare</ParentRole>
      <Position>31</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R32.htm</HtmlFileName>
      <LongName>9955514 - Disclosure - Marketable Investment Securities (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecuritiesTables</Role>
      <ShortName>Marketable Investment Securities (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/MarketableInvestmentSecurities</ParentRole>
      <Position>32</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R33.htm</HtmlFileName>
      <LongName>9955515 - Disclosure - Property and Equipment, Net (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/PropertyandEquipmentNetTables</Role>
      <ShortName>Property and Equipment, Net (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/PropertyandEquipmentNet</ParentRole>
      <Position>33</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R34.htm</HtmlFileName>
      <LongName>9955516 - Disclosure - Goodwill and Other Intangible Assets, Net (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNetTables</Role>
      <ShortName>Goodwill and Other Intangible Assets, Net (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNet</ParentRole>
      <Position>34</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R35.htm</HtmlFileName>
      <LongName>9955517 - Disclosure - Other Accrued and Current Liabilities (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/OtherAccruedandCurrentLiabilitiesTables</Role>
      <ShortName>Other Accrued and Current Liabilities (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/OtherAccruedandCurrentLiabilities</ParentRole>
      <Position>35</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R36.htm</HtmlFileName>
      <LongName>9955518 - Disclosure - Long-Term Debt (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebtTables</Role>
      <ShortName>Long-Term Debt (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/LongTermDebt</ParentRole>
      <Position>36</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R37.htm</HtmlFileName>
      <LongName>9955519 - Disclosure - Leases (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesTables</Role>
      <ShortName>Leases (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/Leases</ParentRole>
      <Position>37</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R38.htm</HtmlFileName>
      <LongName>9955520 - Disclosure - Fair Value Measurements (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/FairValueMeasurementsTables</Role>
      <ShortName>Fair Value Measurements (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/FairValueMeasurements</ParentRole>
      <Position>38</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R39.htm</HtmlFileName>
      <LongName>9955521 - Disclosure - Stock Incentive Plans and Stock Based Compensation (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationTables</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensation</ParentRole>
      <Position>39</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R40.htm</HtmlFileName>
      <LongName>9955522 - Disclosure - Income Taxes (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesTables</Role>
      <ShortName>Income Taxes (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/IncomeTaxes</ParentRole>
      <Position>40</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R41.htm</HtmlFileName>
      <LongName>9955523 - Disclosure - Segment and Related Information (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SegmentandRelatedInformationTables</Role>
      <ShortName>Segment and Related Information (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/SegmentandRelatedInformation</ParentRole>
      <Position>41</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R42.htm</HtmlFileName>
      <LongName>9955524 - Disclosure - Summary of Significant Accounting Policies (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SummaryofSignificantAccountingPoliciesDetails</Role>
      <ShortName>Summary of Significant Accounting Policies (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/SummaryofSignificantAccountingPoliciesPolicies</ParentRole>
      <Position>42</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R43.htm</HtmlFileName>
      <LongName>9955525 - Disclosure - Revenue - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/RevenueNarrativeDetails</Role>
      <ShortName>Revenue - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>43</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R44.htm</HtmlFileName>
      <LongName>9955526 - Disclosure - Revenue - Schedule of Disaggregation of Revenue (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/RevenueScheduleofDisaggregationofRevenueDetails</Role>
      <ShortName>Revenue - Schedule of Disaggregation of Revenue (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>44</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R45.htm</HtmlFileName>
      <LongName>9955527 - Disclosure - Revenue - Schedule of Concentration of Risk, by Risk Factor (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/RevenueScheduleofConcentrationofRiskbyRiskFactorDetails</Role>
      <ShortName>Revenue - Schedule of Concentration of Risk, by Risk Factor (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>45</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R46.htm</HtmlFileName>
      <LongName>9955528 - Disclosure - (Loss) Earnings Per Share - Schedule of Basic and Diluted (Loss) Earnings Per Share (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LossEarningsPerShareScheduleofBasicandDilutedLossEarningsPerShareDetails</Role>
      <ShortName>(Loss) Earnings Per Share - Schedule of Basic and Diluted (Loss) Earnings Per Share (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>46</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R47.htm</HtmlFileName>
      <LongName>9955529 - Disclosure - (Loss) Earnings Per Share - Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LossEarningsPerShareScheduleofAntidilutiveSecuritiesExcludedfromComputationofEarningsPerShareDetails</Role>
      <ShortName>(Loss) Earnings Per Share - Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>47</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R48.htm</HtmlFileName>
      <LongName>9955530 - Disclosure - (Loss) Earnings Per Share - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LossEarningsPerShareNarrativeDetails</Role>
      <ShortName>(Loss) Earnings Per Share - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>48</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R49.htm</HtmlFileName>
      <LongName>9955531 - Disclosure - Marketable Investment Securities - Schedule of Marketable Securities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecuritiesScheduleofMarketableSecuritiesDetails</Role>
      <ShortName>Marketable Investment Securities - Schedule of Marketable Securities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>49</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R50.htm</HtmlFileName>
      <LongName>9955532 - Disclosure - Marketable Investment Securities - Schedule of Unrealized Gain (Loss) on Investments (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecuritiesScheduleofUnrealizedGainLossonInvestmentsDetails</Role>
      <ShortName>Marketable Investment Securities - Schedule of Unrealized Gain (Loss) on Investments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>50</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R51.htm</HtmlFileName>
      <LongName>9955533 - Disclosure - Marketable Investment Securities - Schedule of Available-for-Sale Debt Securities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecuritiesScheduleofAvailableforSaleDebtSecuritiesDetails</Role>
      <ShortName>Marketable Investment Securities - Schedule of Available-for-Sale Debt Securities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>51</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R52.htm</HtmlFileName>
      <LongName>9955534 - Disclosure - Marketable Investment Securities - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/MarketableInvestmentSecuritiesNarrativeDetails</Role>
      <ShortName>Marketable Investment Securities - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>52</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R53.htm</HtmlFileName>
      <LongName>9955535 - Disclosure - Property and Equipment, Net - Schedule of Property and Equipment (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/PropertyandEquipmentNetScheduleofPropertyandEquipmentDetails</Role>
      <ShortName>Property and Equipment, Net - Schedule of Property and Equipment (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>53</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R54.htm</HtmlFileName>
      <LongName>9955536 - Disclosure - Property and Equipment, Net - Schedule of Depreciation Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/PropertyandEquipmentNetScheduleofDepreciationExpenseDetails</Role>
      <ShortName>Property and Equipment, Net - Schedule of Depreciation Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>54</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R55.htm</HtmlFileName>
      <LongName>9955537 - Disclosure - Goodwill and Other Intangible Assets, Net - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNetNarrativeDetails</Role>
      <ShortName>Goodwill and Other Intangible Assets, Net - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>55</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R56.htm</HtmlFileName>
      <LongName>9955538 - Disclosure - Goodwill and Other Intangible Assets, Net - Schedule of Finite-Lived Intangible Assets (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNetScheduleofFiniteLivedIntangibleAssetsDetails</Role>
      <ShortName>Goodwill and Other Intangible Assets, Net - Schedule of Finite-Lived Intangible Assets (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>56</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R57.htm</HtmlFileName>
      <LongName>9955539 - Disclosure - Goodwill and Other Intangible Assets, Net - Schedule of Finite-Lived Intangible Assets, Future Amortization Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/GoodwillandOtherIntangibleAssetsNetScheduleofFiniteLivedIntangibleAssetsFutureAmortizationExpenseDetails</Role>
      <ShortName>Goodwill and Other Intangible Assets, Net - Schedule of Finite-Lived Intangible Assets, Future Amortization Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>57</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R58.htm</HtmlFileName>
      <LongName>9955540 - Disclosure - Other Accrued and Current Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/OtherAccruedandCurrentLiabilitiesDetails</Role>
      <ShortName>Other Accrued and Current Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/OtherAccruedandCurrentLiabilitiesTables</ParentRole>
      <Position>58</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R59.htm</HtmlFileName>
      <LongName>9955541 - Disclosure - Long-Term Debt - Schedule of Long-term Debt Instruments (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebtScheduleofLongtermDebtInstrumentsDetails</Role>
      <ShortName>Long-Term Debt - Schedule of Long-term Debt Instruments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>59</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R60.htm</HtmlFileName>
      <LongName>9955542 - Disclosure - Long-Term Debt - Schedule of Maturities of Long-Term Debt (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebtScheduleofMaturitiesofLongTermDebtDetails</Role>
      <ShortName>Long-Term Debt - Schedule of Maturities of Long-Term Debt (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>60</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R61.htm</HtmlFileName>
      <LongName>9955543 - Disclosure - Long-Term Debt - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebtNarrativeDetails</Role>
      <ShortName>Long-Term Debt - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>61</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R62.htm</HtmlFileName>
      <LongName>9955544 - Disclosure - Long-Term Debt - Schedule of Components of Interest Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LongTermDebtScheduleofComponentsofInterestExpenseDetails</Role>
      <ShortName>Long-Term Debt - Schedule of Components of Interest Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>62</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R63.htm</HtmlFileName>
      <LongName>9955545 - Disclosure - Leases - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesNarrativeDetails</Role>
      <ShortName>Leases - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>63</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R64.htm</HtmlFileName>
      <LongName>9955546 - Disclosure - Leases - Schedule of Balance Sheet Classification of Lease Assets and Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesScheduleofBalanceSheetClassificationofLeaseAssetsandLiabilitiesDetails</Role>
      <ShortName>Leases - Schedule of Balance Sheet Classification of Lease Assets and Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>64</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R65.htm</HtmlFileName>
      <LongName>9955547 - Disclosure - Leases - Schedule of Lease Cost (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesScheduleofLeaseCostDetails</Role>
      <ShortName>Leases - Schedule of Lease Cost (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>65</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R66.htm</HtmlFileName>
      <LongName>9955548 - Disclosure - Leases - Schedule of Other information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesScheduleofOtherinformationDetails</Role>
      <ShortName>Leases - Schedule of Other information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>66</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R67.htm</HtmlFileName>
      <LongName>9955549 - Disclosure - Leases - Schedule of Operating Lease and Finance Lease Maturity (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/LeasesScheduleofOperatingLeaseandFinanceLeaseMaturityDetails</Role>
      <ShortName>Leases - Schedule of Operating Lease and Finance Lease Maturity (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>67</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R68.htm</HtmlFileName>
      <LongName>9955550 - Disclosure - Fair Value Measurements (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/FairValueMeasurementsDetails</Role>
      <ShortName>Fair Value Measurements (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/FairValueMeasurementsTables</ParentRole>
      <Position>68</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R69.htm</HtmlFileName>
      <LongName>9955551 - Disclosure - Commitments and Contingencies (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/CommitmentsandContingenciesDetails</Role>
      <ShortName>Commitments and Contingencies (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/CommitmentsandContingencies</ParentRole>
      <Position>69</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R70.htm</HtmlFileName>
      <LongName>9955552 - Disclosure - Stockholders??? Equity (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockholdersEquityDetails</Role>
      <ShortName>Stockholders??? Equity (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/StockholdersEquity</ParentRole>
      <Position>70</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R71.htm</HtmlFileName>
      <LongName>9955553 - Disclosure - Stock Incentive Plans and Stock Based Compensation - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationNarrativeDetails</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationTables</ParentRole>
      <Position>71</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R72.htm</HtmlFileName>
      <LongName>9955554 - Disclosure - Stock Incentive Plans and Stock Based Compensation - Activity Under Stock Incentive Plan (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationActivityUnderStockIncentivePlanDetails</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation - Activity Under Stock Incentive Plan (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>72</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R73.htm</HtmlFileName>
      <LongName>9955555 - Disclosure - Stock Incentive Plans and Stock Based Compensation - Restricted Stock Units and Performance Stock Units (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationRestrictedStockUnitsandPerformanceStockUnitsDetails</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation - Restricted Stock Units and Performance Stock Units (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>73</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R74.htm</HtmlFileName>
      <LongName>9955556 - Disclosure - Stock Incentive Plans and Stock Based Compensation - Assumptions Used in Fair Value of Stock Options and ESPP (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationAssumptionsUsedinFairValueofStockOptionsandESPPDetails</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation - Assumptions Used in Fair Value of Stock Options and ESPP (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>74</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R75.htm</HtmlFileName>
      <LongName>9955557 - Disclosure - Stock Incentive Plans and Stock Based Compensation - Stock-based Compensation Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/StockIncentivePlansandStockBasedCompensationStockbasedCompensationExpenseDetails</Role>
      <ShortName>Stock Incentive Plans and Stock Based Compensation - Stock-based Compensation Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>75</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R76.htm</HtmlFileName>
      <LongName>9955558 - Disclosure - Income Taxes - Schedule of Components of Income Tax Expense (Benefit) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesScheduleofComponentsofIncomeTaxExpenseBenefitDetails</Role>
      <ShortName>Income Taxes - Schedule of Components of Income Tax Expense (Benefit) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>76</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R77.htm</HtmlFileName>
      <LongName>9955559 - Disclosure - Income Taxes - Schedule of Effective Income Tax Rate Reconciliation (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesScheduleofEffectiveIncomeTaxRateReconciliationDetails</Role>
      <ShortName>Income Taxes - Schedule of Effective Income Tax Rate Reconciliation (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>77</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R78.htm</HtmlFileName>
      <LongName>9955560 - Disclosure - Income Taxes - Schedule of Income Taxes Paid Net Of Refunds (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesScheduleofIncomeTaxesPaidNetOfRefundsDetails</Role>
      <ShortName>Income Taxes - Schedule of Income Taxes Paid Net Of Refunds (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>78</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R79.htm</HtmlFileName>
      <LongName>9955561 - Disclosure - Income Taxes - Schedule of Deferred Tax Assets and Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesScheduleofDeferredTaxAssetsandLiabilitiesDetails</Role>
      <ShortName>Income Taxes - Schedule of Deferred Tax Assets and Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>79</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R80.htm</HtmlFileName>
      <LongName>9955562 - Disclosure - Income Taxes - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/IncomeTaxesNarrativeDetails</Role>
      <ShortName>Income Taxes - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>80</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R81.htm</HtmlFileName>
      <LongName>9955563 - Disclosure - Segment and Related Information - Schedule of Segment Reporting Information, by Segment (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SegmentandRelatedInformationScheduleofSegmentReportingInformationbySegmentDetails</Role>
      <ShortName>Segment and Related Information - Schedule of Segment Reporting Information, by Segment (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>81</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R82.htm</HtmlFileName>
      <LongName>9955564 - Disclosure - Segment and Related Information - Schedule of Segment Reporting Information, by Segment (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SegmentandRelatedInformationScheduleofSegmentReportingInformationbySegmentDetails_1</Role>
      <ShortName>Segment and Related Information - Schedule of Segment Reporting Information, by Segment (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>82</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R83.htm</HtmlFileName>
      <LongName>9955565 - Disclosure - Segment and Related Information - Narrative (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SegmentandRelatedInformationNarrativeDetails</Role>
      <ShortName>Segment and Related Information - Narrative (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>83</Position>
    </Report>
    <Report instance="cstl-20251231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R84.htm</HtmlFileName>
      <LongName>9955566 - Disclosure - Subsequent Events (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.castlebiosciences.com/role/SubsequentEventsDetails</Role>
      <ShortName>Subsequent Events (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.castlebiosciences.com/role/SubsequentEvents</ParentRole>
      <Position>84</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="cstl-20251231.htm">cstl-20251231.htm</File>
    <File>cstl-20251231.xsd</File>
    <File>cstl-20251231_cal.xml</File>
    <File>cstl-20251231_def.xml</File>
    <File>cstl-20251231_lab.xml</File>
    <File>cstl-20251231_pre.xml</File>
  </InputFiles>
  <SupplementalFiles>
    <File>cstl-20251231_g1.jpg</File>
  </SupplementalFiles>
  <BaseTaxonomies>
    <BaseTaxonomy items="1050">http://fasb.org/us-gaap/2025</BaseTaxonomy>
    <BaseTaxonomy items="15">http://xbrl.sec.gov/cyd/2025</BaseTaxonomy>
    <BaseTaxonomy items="39">http://xbrl.sec.gov/dei/2025</BaseTaxonomy>
    <BaseTaxonomy items="30">http://xbrl.sec.gov/ecd/2025</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>true</HasCalculationLinkbase>
</FilingSummary>
