<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.22.1</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>251</ContextCount>
  <ElementCount>441</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>false</FootnotesReported>
  <SegmentCount>91</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>9</UnitCount>
  <MyReports>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>100000 - Document - Document and Entity Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DocumentDocumentAndEntityInformation</Role>
      <ShortName>Document and Entity Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>100010 - Statement - Balance Sheets</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_StatementBalanceSheets</Role>
      <ShortName>Balance Sheets</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>100030 - Statement - Balance Sheets (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_StatementBalanceSheetsParenthetical</Role>
      <ShortName>Balance Sheets (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R4.htm</HtmlFileName>
      <LongName>100040 - Statement - Statements of Operations</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/StatementStatementsOfOperations1</Role>
      <ShortName>Statements of Operations</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R5.htm</HtmlFileName>
      <LongName>100050 - Statement - Statements of Operations (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/StatementStatementsOfOperationsParenthetical</Role>
      <ShortName>Statements of Operations (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>5</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R6.htm</HtmlFileName>
      <LongName>100060 - Statement - Statements of Comprehensive Loss</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/StatementStatementsOfComprehensiveLoss</Role>
      <ShortName>Statements of Comprehensive Loss</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>6</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R7.htm</HtmlFileName>
      <LongName>100070 - Statement - Statements of Redeemable Convertible Preferred Stock and Stockholders' Equity (Deficit)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_StatementStatementsOfRedeemableConvertiblePreferredStockAndStockholdersEquityDeficit</Role>
      <ShortName>Statements of Redeemable Convertible Preferred Stock and Stockholders' Equity (Deficit)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>7</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R8.htm</HtmlFileName>
      <LongName>100080 - Statement - Statements of Redeemable Convertible Preferred Stock and Stockholders' Equity (Deficit) (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_StatementStatementsOfRedeemableConvertiblePreferredStockAndStockholdersEquityDeficitParenthetical</Role>
      <ShortName>Statements of Redeemable Convertible Preferred Stock and Stockholders' Equity (Deficit) (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>8</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R9.htm</HtmlFileName>
      <LongName>100090 - Statement - Statements of Cash Flows</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_StatementStatementsOfCashFlows</Role>
      <ShortName>Statements of Cash Flows</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>9</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R10.htm</HtmlFileName>
      <LongName>100100 - Disclosure - The Company</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureTheCompany</Role>
      <ShortName>The Company</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>10</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R11.htm</HtmlFileName>
      <LongName>100110 - Disclosure - Summary of Significant Accounting Policies</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>11</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R12.htm</HtmlFileName>
      <LongName>100120 - Disclosure - Fair Value Measurements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureFairValueMeasurements</Role>
      <ShortName>Fair Value Measurements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>12</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R13.htm</HtmlFileName>
      <LongName>100130 - Disclosure - Marketable Securities</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecurities</Role>
      <ShortName>Marketable Securities</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>13</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R14.htm</HtmlFileName>
      <LongName>100140 - Disclosure - Property and Equipment, Net</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosurePropertyAndEquipmentNet</Role>
      <ShortName>Property and Equipment, Net</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>14</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R15.htm</HtmlFileName>
      <LongName>100150 - Disclosure - Accrued and Other Liabilities, Current and Noncurrent</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureAccruedAndOtherLiabilitiesCurrentAndNoncurrent</Role>
      <ShortName>Accrued and Other Liabilities, Current and Noncurrent</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>15</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R16.htm</HtmlFileName>
      <LongName>100160 - Disclosure - Research and Collaboration Arrangements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangements</Role>
      <ShortName>Research and Collaboration Arrangements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>16</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R17.htm</HtmlFileName>
      <LongName>100170 - Disclosure - License Arrangements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureLicenseArrangements</Role>
      <ShortName>License Arrangements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>17</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R18.htm</HtmlFileName>
      <LongName>100180 - Disclosure - Commitments and Contingencies</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommitmentsAndContingencies</Role>
      <ShortName>Commitments and Contingencies</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>18</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R19.htm</HtmlFileName>
      <LongName>100190 - Disclosure - Income Taxes</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxes</Role>
      <ShortName>Income Taxes</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>19</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R20.htm</HtmlFileName>
      <LongName>100200 - Disclosure - Redeemable Convertible Preferred Stock</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRedeemableConvertiblePreferredStock</Role>
      <ShortName>Redeemable Convertible Preferred Stock</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>20</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R21.htm</HtmlFileName>
      <LongName>100210 - Disclosure - Common Stock</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStock</Role>
      <ShortName>Common Stock</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>21</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R22.htm</HtmlFileName>
      <LongName>100220 - Disclosure - Stock-based Compensation</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensation</Role>
      <ShortName>Stock-based Compensation</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>22</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R23.htm</HtmlFileName>
      <LongName>100230 - Disclosure - Common Stock Warrants</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStockWarrants</Role>
      <ShortName>Common Stock Warrants</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>23</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R24.htm</HtmlFileName>
      <LongName>100240 - Disclosure - Net Loss Per Share, Basic and Diluted</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureNetLossPerShareBasicAndDiluted1</Role>
      <ShortName>Net Loss Per Share, Basic and Diluted</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>24</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R25.htm</HtmlFileName>
      <LongName>100250 - Disclosure - Derivative Liability</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureDerivativeLiability</Role>
      <ShortName>Derivative Liability</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>25</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R26.htm</HtmlFileName>
      <LongName>100260 - Disclosure - Related Party Transactions</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRelatedPartyTransactions</Role>
      <ShortName>Related Party Transactions</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>26</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R27.htm</HtmlFileName>
      <LongName>100270 - Disclosure - 401(K) Plan</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_Disclosure401KPlan</Role>
      <ShortName>401(K) Plan</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>27</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R28.htm</HtmlFileName>
      <LongName>100280 - Disclosure - Summary of Significant Accounting Policies (Policies)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies (Policies)</ShortName>
      <MenuCategory>Policies</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPolicies</ParentRole>
      <Position>28</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R29.htm</HtmlFileName>
      <LongName>100290 - Disclosure - Summary of Significant Accounting Policies (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesTables</Role>
      <ShortName>Summary of Significant Accounting Policies (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPolicies</ParentRole>
      <Position>29</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R30.htm</HtmlFileName>
      <LongName>100300 - Disclosure - Fair Value Measurements (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureFairValueMeasurementsTables</Role>
      <ShortName>Fair Value Measurements (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureFairValueMeasurements</ParentRole>
      <Position>30</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R31.htm</HtmlFileName>
      <LongName>100310 - Disclosure - Marketable Securities (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecuritiesTables</Role>
      <ShortName>Marketable Securities (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecurities</ParentRole>
      <Position>31</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R32.htm</HtmlFileName>
      <LongName>100320 - Disclosure - Property and Equipment, Net (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosurePropertyAndEquipmentNetTables</Role>
      <ShortName>Property and Equipment, Net (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosurePropertyAndEquipmentNet</ParentRole>
      <Position>32</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R33.htm</HtmlFileName>
      <LongName>100330 - Disclosure - Accrued and Other Liabilities, Current and Noncurrent (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureAccruedAndOtherLiabilitiesCurrentAndNoncurrentTables</Role>
      <ShortName>Accrued and Other Liabilities, Current and Noncurrent (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureAccruedAndOtherLiabilitiesCurrentAndNoncurrent</ParentRole>
      <Position>33</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R34.htm</HtmlFileName>
      <LongName>100340 - Disclosure - Research and Collaboration Arrangements (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsTables</Role>
      <ShortName>Research and Collaboration Arrangements (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangements</ParentRole>
      <Position>34</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R35.htm</HtmlFileName>
      <LongName>100350 - Disclosure - Commitments and Contingencies (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommitmentsAndContingenciesTables</Role>
      <ShortName>Commitments and Contingencies (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommitmentsAndContingencies</ParentRole>
      <Position>35</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R36.htm</HtmlFileName>
      <LongName>100360 - Disclosure - Income Taxes (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxesTables</Role>
      <ShortName>Income Taxes (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxes</ParentRole>
      <Position>36</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R37.htm</HtmlFileName>
      <LongName>100370 - Disclosure - Redeemable Convertible Preferred Stock (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRedeemableConvertiblePreferredStockTables</Role>
      <ShortName>Redeemable Convertible Preferred Stock (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRedeemableConvertiblePreferredStock</ParentRole>
      <Position>37</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R38.htm</HtmlFileName>
      <LongName>100380 - Disclosure - Common Stock (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStockTables</Role>
      <ShortName>Common Stock (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStock</ParentRole>
      <Position>38</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R39.htm</HtmlFileName>
      <LongName>100390 - Disclosure - Stock-based Compensation (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensationTables</Role>
      <ShortName>Stock-based Compensation (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensation</ParentRole>
      <Position>39</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R40.htm</HtmlFileName>
      <LongName>100400 - Disclosure - Net Loss Per Share, Basic and Diluted (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureNetLossPerShareBasicAndDilutedTables</Role>
      <ShortName>Net Loss Per Share, Basic and Diluted (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureNetLossPerShareBasicAndDiluted1</ParentRole>
      <Position>40</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R41.htm</HtmlFileName>
      <LongName>100410 - Disclosure - The Company - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureTheCompanyAdditionalInformationDetails</Role>
      <ShortName>The Company - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>41</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R42.htm</HtmlFileName>
      <LongName>100420 - Disclosure - Summary of Significant Accounting Policies - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesAdditionalInformationDetails</Role>
      <ShortName>Summary of Significant Accounting Policies - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>42</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R43.htm</HtmlFileName>
      <LongName>100430 - Disclosure - Summary of Significant Accounting Policies - Schedule of Concentration of Risk (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesScheduleOfConcentrationOfRiskDetails</Role>
      <ShortName>Summary of Significant Accounting Policies - Schedule of Concentration of Risk (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>43</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R44.htm</HtmlFileName>
      <LongName>100440 - Disclosure - Summary of Significant Accounting Policies - Schedule of Concentration of Risk (Details) (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesScheduleOfConcentrationOfRiskDetailsParenthetical</Role>
      <ShortName>Summary of Significant Accounting Policies - Schedule of Concentration of Risk (Details) (Parenthetical)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>44</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R45.htm</HtmlFileName>
      <LongName>100450 - Disclosure - Summary of Significant Accounting Policies - Schedule of Revenues by Geographic Region (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureSummaryOfSignificantAccountingPoliciesScheduleOfRevenuesByGeographicRegionDetails</Role>
      <ShortName>Summary of Significant Accounting Policies - Schedule of Revenues by Geographic Region (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>45</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R46.htm</HtmlFileName>
      <LongName>100460 - Disclosure - Summary of Significant Accounting Policies - Schedule of Impact of Adoption of New Accounting Standard (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureSummaryOfSignificantAccountingPoliciesScheduleOfImpactOfAdoptionOfNewAccountingStandardDetails</Role>
      <ShortName>Summary of Significant Accounting Policies - Schedule of Impact of Adoption of New Accounting Standard (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>46</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R47.htm</HtmlFileName>
      <LongName>100470 - Disclosure - Fair Value Measurements - Fair Value Hierarchy for Financial Assets and Financial Liabilities Measured at Fair Value on Recurring Basis (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureFairValueMeasurementsFairValueHierarchyForFinancialAssetsAndFinancialLiabilitiesMeasuredAtFairValueOnRecurringBasisDetails</Role>
      <ShortName>Fair Value Measurements - Fair Value Hierarchy for Financial Assets and Financial Liabilities Measured at Fair Value on Recurring Basis (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>47</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R48.htm</HtmlFileName>
      <LongName>100480 - Disclosure - Fair Value Measurements - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureFairValueMeasurementsAdditionalInformationDetails</Role>
      <ShortName>Fair Value Measurements - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>48</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R49.htm</HtmlFileName>
      <LongName>100490 - Disclosure - Fair Value Measurements - Summary of Changes in Fair Value of Level 3 Derivative Liability (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureFairValueMeasurementsSummaryOfChangesInFairValueOfLevel3DerivativeLiabilityDetails</Role>
      <ShortName>Fair Value Measurements - Summary of Changes in Fair Value of Level 3 Derivative Liability (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>49</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R50.htm</HtmlFileName>
      <LongName>100500 - Disclosure - Marketable Securities - Summary of Available for Sale Securities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecuritiesSummaryOfAvailableForSaleSecuritiesDetails</Role>
      <ShortName>Marketable Securities - Summary of Available for Sale Securities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>50</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R51.htm</HtmlFileName>
      <LongName>100510 - Disclosure - Marketable Securities (Additional Information) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecuritiesAdditionalInformationDetails</Role>
      <ShortName>Marketable Securities (Additional Information) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureMarketableSecuritiesTables</ParentRole>
      <Position>51</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R52.htm</HtmlFileName>
      <LongName>100520 - Disclosure - Property and Equipment, Net - Schedule of Property and Equipment, Net (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosurePropertyAndEquipmentNetScheduleOfPropertyAndEquipmentNetDetails</Role>
      <ShortName>Property and Equipment, Net - Schedule of Property and Equipment, Net (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>52</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R53.htm</HtmlFileName>
      <LongName>100530 - Disclosure - Property and Equipment, Net - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosurePropertyAndEquipmentNetAdditionalInformationDetails</Role>
      <ShortName>Property and Equipment, Net - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>53</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R54.htm</HtmlFileName>
      <LongName>100540 - Disclosure - Accrued and Other Liabilities, Current and Noncurrent - Summary of Accrued Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureAccruedAndOtherLiabilitiesCurrentAndNoncurrentSummaryOfAccruedLiabilitiesDetails</Role>
      <ShortName>Accrued and Other Liabilities, Current and Noncurrent - Summary of Accrued Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>54</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R55.htm</HtmlFileName>
      <LongName>100550 - Disclosure - Accrued and Other Liabilities, Current and Noncurrent - Summary of Other Liabilities, Noncurrent (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureAccruedAndOtherLiabilitiesCurrentAndNoncurrentSummaryOfOtherLiabilitiesNoncurrentDetails</Role>
      <ShortName>Accrued and Other Liabilities, Current and Noncurrent - Summary of Other Liabilities, Noncurrent (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>55</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R56.htm</HtmlFileName>
      <LongName>100560 - Disclosure - Research and Collaboration Arrangements - Summary of Collaboration and License Revenue (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsSummaryOfCollaborationAndLicenseRevenueDetails</Role>
      <ShortName>Research and Collaboration Arrangements - Summary of Collaboration and License Revenue (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>56</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R57.htm</HtmlFileName>
      <LongName>100570 - Disclosure - Research and Collaboration Arrangements - Summary of Deferred Revenue (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsSummaryOfDeferredRevenueDetails</Role>
      <ShortName>Research and Collaboration Arrangements - Summary of Deferred Revenue (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>57</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R58.htm</HtmlFileName>
      <LongName>100580 - Disclosure - Research and Collaboration Arrangements - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsAdditionalInformationDetails</Role>
      <ShortName>Research and Collaboration Arrangements - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>58</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R59.htm</HtmlFileName>
      <LongName>100590 - Disclosure - Research and Collaboration Arrangements - Additional Information (Details 1)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsAdditionalInformationDetails1</Role>
      <ShortName>Research and Collaboration Arrangements - Additional Information (Details 1)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>59</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R60.htm</HtmlFileName>
      <LongName>100600 - Disclosure - Research and Collaboration Arrangements - CRF Agreement - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsCRFAgreementAdditionalInformationDetails</Role>
      <ShortName>Research and Collaboration Arrangements - CRF Agreement - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>60</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R61.htm</HtmlFileName>
      <LongName>100610 - Disclosure - Research and Collaboration Arrangements - Roche Agreement - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsRocheAgreementAdditionalInformationDetails</Role>
      <ShortName>Research and Collaboration Arrangements - Roche Agreement - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>61</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R62.htm</HtmlFileName>
      <LongName>100630 - Disclosure - Research and Collaboration Arrangements - CFF - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsCFFAdditionalInformationDetails</Role>
      <ShortName>Research and Collaboration Arrangements - CFF - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>62</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R63.htm</HtmlFileName>
      <LongName>100640 - Disclosure - Research and Collaboration Arrangements - CFF - Additional Information (Details 1)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureResearchAndCollaborationArrangementsCFFAdditionalInformationDetails1</Role>
      <ShortName>Research and Collaboration Arrangements - CFF - Additional Information (Details 1)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>63</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R64.htm</HtmlFileName>
      <LongName>100650 - Disclosure - License Arrangements - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureLicenseArrangementsAdditionalInformationDetails</Role>
      <ShortName>License Arrangements - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>64</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R65.htm</HtmlFileName>
      <LongName>100660 - Disclosure - Commitments and Contingencies - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommitmentsAndContingenciesAdditionalInformationDetails</Role>
      <ShortName>Commitments and Contingencies - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>65</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R66.htm</HtmlFileName>
      <LongName>100670 - Disclosure - Commitments and Contingencies - summary of Components of Lease Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureCommitmentsAndContingenciesSummaryOfComponentsOfLeaseExpenseDetails</Role>
      <ShortName>Commitments and Contingencies - summary of Components of Lease Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>66</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R67.htm</HtmlFileName>
      <LongName>100680 - Disclosure - Commitments and Contingencies - Summary of Supplemental Information Related to Leases (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureCommitmentsAndContingenciesSummaryOfSupplementalInformationRelatedToLeasesDetails</Role>
      <ShortName>Commitments and Contingencies - Summary of Supplemental Information Related to Leases (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>67</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R68.htm</HtmlFileName>
      <LongName>100690 - Disclosure - Commitments and Contingencies - Summary of Maturities of Lease Liabilities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureCommitmentsAndContingenciesSummaryOfMaturitiesOfLeaseLiabilitiesDetails</Role>
      <ShortName>Commitments and Contingencies - Summary of Maturities of Lease Liabilities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>68</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R69.htm</HtmlFileName>
      <LongName>100700 - Disclosure - Income Taxes - Schedule of Effective Tax Rate of Income Tax Expense (Benefit) Differs from Federal Statutory Rate (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxesScheduleOfEffectiveTaxRateOfIncomeTaxExpenseBenefitDiffersFromFederalStatutoryRateDetails</Role>
      <ShortName>Income Taxes - Schedule of Effective Tax Rate of Income Tax Expense (Benefit) Differs from Federal Statutory Rate (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>69</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R70.htm</HtmlFileName>
      <LongName>100710 - Disclosure - Income Taxes - Schedule of Tax Effects of Temporary Differences to Significant Components of Deferred Taxes (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxesScheduleOfTaxEffectsOfTemporaryDifferencesToSignificantComponentsOfDeferredTaxesDetails</Role>
      <ShortName>Income Taxes - Schedule of Tax Effects of Temporary Differences to Significant Components of Deferred Taxes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>70</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R71.htm</HtmlFileName>
      <LongName>100720 - Disclosure - Income Taxes - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxesAdditionalInformationDetails</Role>
      <ShortName>Income Taxes - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>71</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R72.htm</HtmlFileName>
      <LongName>100730 - Disclosure - Income Taxes - Reconciliation of Beginning and Ending Unrecognized Tax Benefits (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureIncomeTaxesReconciliationOfBeginningAndEndingUnrecognizedTaxBenefitsDetails</Role>
      <ShortName>Income Taxes - Reconciliation of Beginning and Ending Unrecognized Tax Benefits (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>72</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R73.htm</HtmlFileName>
      <LongName>100740 - Disclosure - Redeemable Convertible Preferred Stock - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRedeemableConvertiblePreferredStockAdditionalInformationDetails</Role>
      <ShortName>Redeemable Convertible Preferred Stock - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>73</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R74.htm</HtmlFileName>
      <LongName>100750 - Disclosure - Redeemable Convertible Preferred Stock - Summary of Redeemable Convertible Preferred Stock (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRedeemableConvertiblePreferredStockSummaryOfRedeemableConvertiblePreferredStockDetails</Role>
      <ShortName>Redeemable Convertible Preferred Stock - Summary of Redeemable Convertible Preferred Stock (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>74</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R75.htm</HtmlFileName>
      <LongName>100760 - Disclosure - Common Stock - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStockAdditionalInformationDetails</Role>
      <ShortName>Common Stock - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>75</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R76.htm</HtmlFileName>
      <LongName>100770 - Disclosure - Common Stock - Schedule of Common Share Reserved for Future Issuance (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStockScheduleOfCommonShareReservedForFutureIssuanceDetails</Role>
      <ShortName>Common Stock - Schedule of Common Share Reserved for Future Issuance (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>76</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R77.htm</HtmlFileName>
      <LongName>100780 - Disclosure - Stock-based Compensation - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensationAdditionalInformationDetails</Role>
      <ShortName>Stock-based Compensation - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>77</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R78.htm</HtmlFileName>
      <LongName>100790 - Disclosure - Stock-based Compensation - Summary of Stock Options Activity (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensationSummaryOfStockOptionsActivityDetails</Role>
      <ShortName>Stock-based Compensation - Summary of Stock Options Activity (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>78</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R79.htm</HtmlFileName>
      <LongName>100800 - Disclosure - Stock-based Compensation - Summary of Stock Compensation Expense for Employees and Nonemployees by Function (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensationSummaryOfStockCompensationExpenseForEmployeesAndNonemployeesByFunctionDetails</Role>
      <ShortName>Stock-based Compensation - Summary of Stock Compensation Expense for Employees and Nonemployees by Function (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>79</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R80.htm</HtmlFileName>
      <LongName>100810 - Disclosure - Stock-based Compensation - Schedule of Assumptions Used in Black-Scholes Valuation Model to Estimate Fair Value of Stock Options (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureStockBasedCompensationScheduleOfAssumptionsUsedInBlackScholesValuationModelToEstimateFairValueOfStockOptionsDetails</Role>
      <ShortName>Stock-based Compensation - Schedule of Assumptions Used in Black-Scholes Valuation Model to Estimate Fair Value of Stock Options (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>80</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R81.htm</HtmlFileName>
      <LongName>100820 - Disclosure - Common Stock Warrants - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureCommonStockWarrantsAdditionalInformationDetails</Role>
      <ShortName>Common Stock Warrants - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>81</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R82.htm</HtmlFileName>
      <LongName>100830 - Disclosure - Net Loss Per Share, Basic and Diluted - Computation of Basic and Diluted Net Loss Per Share (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureNetLossPerShareBasicAndDilutedComputationOfBasicAndDilutedNetLossPerShareDetails</Role>
      <ShortName>Net Loss Per Share, Basic and Diluted - Computation of Basic and Diluted Net Loss Per Share (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>82</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R83.htm</HtmlFileName>
      <LongName>100840 - Disclosure - Net Loss Per Share, Basic and Diluted - Outstanding Potentially Dilutive Securities Excluded From Computation of Diluted Net Loss Per Share (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/DisclosureNetLossPerShareBasicAndDilutedOutstandingPotentiallyDilutiveSecuritiesExcludedFromComputationOfDilutedNetLossPerShareDetails</Role>
      <ShortName>Net Loss Per Share, Basic and Diluted - Outstanding Potentially Dilutive Securities Excluded From Computation of Diluted Net Loss Per Share (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>83</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R84.htm</HtmlFileName>
      <LongName>100850 - Disclosure - Derivative Liability - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureDerivativeLiabilityAdditionalInformationDetails</Role>
      <ShortName>Derivative Liability - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>84</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R85.htm</HtmlFileName>
      <LongName>100860 - Disclosure - Related Party Transactions - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_DisclosureRelatedPartyTransactionsAdditionalInformationDetails</Role>
      <ShortName>Related Party Transactions - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>85</Position>
    </Report>
    <Report instance="fdmt-20211231.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R86.htm</HtmlFileName>
      <LongName>100870 - Disclosure - 401(K) Plan - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.4dmoleculartherapeutics.com/20211231/taxonomy/role/Role_Disclosure401KPlanAdditionalInformationDetails</Role>
      <ShortName>401(K) Plan - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>86</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" original="fdmt-20211231.htm">fdmt-20211231.htm</File>
    <File>fdmt-20211231.xsd</File>
    <File>fdmt-20211231_cal.xml</File>
    <File>fdmt-20211231_def.xml</File>
    <File>fdmt-20211231_lab.xml</File>
    <File>fdmt-20211231_pre.xml</File>
    <File>fdmt-ex23_1.htm</File>
    <File>fdmt-ex31_1.htm</File>
    <File>fdmt-ex31_2.htm</File>
    <File>fdmt-ex32_1.htm</File>
    <File>fdmt-ex4_1.htm</File>
  </InputFiles>
  <SupplementalFiles>
    <File>img227133604_0.jpg</File>
    <File>img227133604_1.jpg</File>
    <File>img227133604_10.jpg</File>
    <File>img227133604_11.jpg</File>
    <File>img227133604_2.jpg</File>
    <File>img227133604_3.jpg</File>
    <File>img227133604_4.jpg</File>
    <File>img227133604_5.jpg</File>
    <File>img227133604_6.jpg</File>
    <File>img227133604_7.jpg</File>
    <File>img227133604_8.jpg</File>
    <File>img227133604_9.jpg</File>
  </SupplementalFiles>
  <BaseTaxonomies>
    <BaseTaxonomy items="773">http://fasb.org/us-gaap/2021-01-31</BaseTaxonomy>
    <BaseTaxonomy items="38">http://xbrl.sec.gov/dei/2021q4</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>true</HasCalculationLinkbase>
</FilingSummary>
