<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2024"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:xlink="http://www.w3.org/1999/xlink">
    <link:schemaRef xlink:href="fdmt-20250228.xsd" xlink:type="simple"/>
    <context id="C_0c130b7c-907f-4980-abbb-1282aba9e8ae">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0001650648</identifier>
        </entity>
        <period>
            <startDate>2025-02-28</startDate>
            <endDate>2025-02-28</endDate>
        </period>
    </context>
    <dei:EntityCentralIndexKey
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_023138ec-07c5-43d7-9344-311e5b1b729b">0001650648</dei:EntityCentralIndexKey>
    <dei:AmendmentFlag
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_e06fc27d-f15e-4504-82ca-07857b57af04">false</dei:AmendmentFlag>
    <dei:DocumentType
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_957be833-8543-4a69-9fb4-4c55313e35dc">8-K</dei:DocumentType>
    <dei:DocumentPeriodEndDate
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_47ffb27d-037b-43d2-a0ca-4981beb4d732">2025-02-28</dei:DocumentPeriodEndDate>
    <dei:EntityRegistrantName
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_91b85dbb-6391-4f98-b67c-9c01f2411951">4D Molecular Therapeutics Inc.</dei:EntityRegistrantName>
    <dei:EntityIncorporationStateCountryCode
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_dc9a8642-d998-4243-b381-748f206beed7">DE</dei:EntityIncorporationStateCountryCode>
    <dei:EntityFileNumber
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_dbbba94b-8b8c-44f6-a09d-1f1561225f74">001-39782</dei:EntityFileNumber>
    <dei:EntityTaxIdentificationNumber
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_efcfd436-b307-4ce6-9db4-6c32b35068d1">47-3506994</dei:EntityTaxIdentificationNumber>
    <dei:EntityAddressAddressLine1
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_c3664dd7-8d6e-4cea-b336-44a5f32a0d6b">5858 HORTON STREET</dei:EntityAddressAddressLine1>
    <dei:EntityAddressAddressLine2
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_4f957927-afd0-4ebb-9d8a-1f568bd26364">#455</dei:EntityAddressAddressLine2>
    <dei:EntityAddressCityOrTown
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_427ffcce-3837-4281-a6fc-da4d404fb511">EMERYVILLE</dei:EntityAddressCityOrTown>
    <dei:EntityAddressStateOrProvince
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_72cfa919-8080-4f62-9c2c-350e0919b47d">CA</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressPostalZipCode
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_1f8a996d-9d48-4af1-9f37-c24545681d65">94608</dei:EntityAddressPostalZipCode>
    <dei:CityAreaCode
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_10620a3c-9283-46b9-ba77-1491a01bc1db">510</dei:CityAreaCode>
    <dei:LocalPhoneNumber
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_a5304bc2-4bcd-460e-8b5f-5883cd2d7e84">505-2680</dei:LocalPhoneNumber>
    <dei:WrittenCommunications
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_7e595b04-93bb-4d29-9f08-cba59206252f">false</dei:WrittenCommunications>
    <dei:SolicitingMaterial
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_3b7b2850-12f3-4ff1-a48c-fa63d0a03a68">false</dei:SolicitingMaterial>
    <dei:PreCommencementTenderOffer
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_81cbc17c-43f7-4e0c-8c2b-88b21ce9e6bc">false</dei:PreCommencementTenderOffer>
    <dei:PreCommencementIssuerTenderOffer
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_19659a64-3788-451c-b6a1-07163fde81ad">false</dei:PreCommencementIssuerTenderOffer>
    <dei:Security12bTitle
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_7ce61b3b-32f2-4610-948e-e9eb46e10f4c">Common Stock, $0.0001 par value per share</dei:Security12bTitle>
    <dei:TradingSymbol
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_6bd58ab7-f0a3-4be0-9a98-b34762e02576">FDMT</dei:TradingSymbol>
    <dei:SecurityExchangeName
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_db53d5cb-3b71-47e6-b274-9caa601084d0">NASDAQ</dei:SecurityExchangeName>
    <dei:EntityEmergingGrowthCompany
      contextRef="C_0c130b7c-907f-4980-abbb-1282aba9e8ae"
      id="F_6782603f-e039-49db-8a82-b3bc688762b5">false</dei:EntityEmergingGrowthCompany>
</xbrl>
