<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2026"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:xlink="http://www.w3.org/1999/xlink">
    <link:schemaRef xlink:href="mlm-20260629.xsd" xlink:type="simple"/>
    <context id="AsOf2026-06-29">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000916076</identifier>
        </entity>
        <period>
            <startDate>2026-06-29</startDate>
            <endDate>2026-06-29</endDate>
        </period>
    </context>
    <dei:AmendmentFlag contextRef="AsOf2026-06-29" id="Fact000003">false</dei:AmendmentFlag>
    <dei:EntityCentralIndexKey contextRef="AsOf2026-06-29" id="Fact000004">0000916076</dei:EntityCentralIndexKey>
    <dei:DocumentType contextRef="AsOf2026-06-29" id="Fact000009">8-K</dei:DocumentType>
    <dei:DocumentType contextRef="AsOf2026-06-29" id="Fact000010">8-K</dei:DocumentType>
    <dei:DocumentPeriodEndDate contextRef="AsOf2026-06-29" id="Fact000011">2026-06-29</dei:DocumentPeriodEndDate>
    <dei:EntityRegistrantName contextRef="AsOf2026-06-29" id="Fact000012">Martin Marietta Materials, Inc.</dei:EntityRegistrantName>
    <dei:EntityRegistrantName contextRef="AsOf2026-06-29" id="Fact000013">Martin Marietta Materials, Inc.</dei:EntityRegistrantName>
    <dei:EntityIncorporationStateCountryCode contextRef="AsOf2026-06-29" id="Fact000014">NC</dei:EntityIncorporationStateCountryCode>
    <dei:EntityIncorporationStateCountryCode contextRef="AsOf2026-06-29" id="Fact000015">NC</dei:EntityIncorporationStateCountryCode>
    <dei:EntityFileNumber contextRef="AsOf2026-06-29" id="Fact000016">1-12744</dei:EntityFileNumber>
    <dei:EntityFileNumber contextRef="AsOf2026-06-29" id="Fact000017">1-12744</dei:EntityFileNumber>
    <dei:EntityTaxIdentificationNumber contextRef="AsOf2026-06-29" id="Fact000018">56-1848578</dei:EntityTaxIdentificationNumber>
    <dei:EntityTaxIdentificationNumber contextRef="AsOf2026-06-29" id="Fact000019">56-1848578</dei:EntityTaxIdentificationNumber>
    <dei:EntityAddressAddressLine1 contextRef="AsOf2026-06-29" id="Fact000020">4123 Parklake Avenue</dei:EntityAddressAddressLine1>
    <dei:EntityAddressAddressLine1 contextRef="AsOf2026-06-29" id="Fact000021">4123 Parklake Avenue</dei:EntityAddressAddressLine1>
    <dei:EntityAddressCityOrTown contextRef="AsOf2026-06-29" id="Fact000022">Raleigh</dei:EntityAddressCityOrTown>
    <dei:EntityAddressCityOrTown contextRef="AsOf2026-06-29" id="Fact000023">Raleigh</dei:EntityAddressCityOrTown>
    <dei:EntityAddressStateOrProvince contextRef="AsOf2026-06-29" id="Fact000024">NC</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressStateOrProvince contextRef="AsOf2026-06-29" id="Fact000025">NC</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressPostalZipCode contextRef="AsOf2026-06-29" id="Fact000026">27612</dei:EntityAddressPostalZipCode>
    <dei:EntityAddressPostalZipCode contextRef="AsOf2026-06-29" id="Fact000027">27612</dei:EntityAddressPostalZipCode>
    <dei:CityAreaCode contextRef="AsOf2026-06-29" id="Fact000028">919</dei:CityAreaCode>
    <dei:CityAreaCode contextRef="AsOf2026-06-29" id="Fact000029">919</dei:CityAreaCode>
    <dei:LocalPhoneNumber contextRef="AsOf2026-06-29" id="Fact000030">781-4550</dei:LocalPhoneNumber>
    <dei:LocalPhoneNumber contextRef="AsOf2026-06-29" id="Fact000031">781-4550</dei:LocalPhoneNumber>
    <dei:WrittenCommunications contextRef="AsOf2026-06-29" id="Fact000032">false</dei:WrittenCommunications>
    <dei:WrittenCommunications contextRef="AsOf2026-06-29" id="Fact000033">false</dei:WrittenCommunications>
    <dei:SolicitingMaterial contextRef="AsOf2026-06-29" id="Fact000034">false</dei:SolicitingMaterial>
    <dei:SolicitingMaterial contextRef="AsOf2026-06-29" id="Fact000035">false</dei:SolicitingMaterial>
    <dei:PreCommencementTenderOffer contextRef="AsOf2026-06-29" id="Fact000036">false</dei:PreCommencementTenderOffer>
    <dei:PreCommencementTenderOffer contextRef="AsOf2026-06-29" id="Fact000037">false</dei:PreCommencementTenderOffer>
    <dei:PreCommencementIssuerTenderOffer contextRef="AsOf2026-06-29" id="Fact000038">false</dei:PreCommencementIssuerTenderOffer>
    <dei:PreCommencementIssuerTenderOffer contextRef="AsOf2026-06-29" id="Fact000039">false</dei:PreCommencementIssuerTenderOffer>
    <dei:Security12bTitle contextRef="AsOf2026-06-29" id="Fact000040">Common Stock, $0.01 par value per share</dei:Security12bTitle>
    <dei:Security12bTitle contextRef="AsOf2026-06-29" id="Fact000041">Common Stock, $0.01 par value per share</dei:Security12bTitle>
    <dei:TradingSymbol contextRef="AsOf2026-06-29" id="Fact000042">MLM</dei:TradingSymbol>
    <dei:TradingSymbol contextRef="AsOf2026-06-29" id="Fact000043">MLM</dei:TradingSymbol>
    <dei:SecurityExchangeName contextRef="AsOf2026-06-29" id="Fact000044">NYSE</dei:SecurityExchangeName>
    <dei:SecurityExchangeName contextRef="AsOf2026-06-29" id="Fact000045">NYSE</dei:SecurityExchangeName>
    <dei:EntityEmergingGrowthCompany contextRef="AsOf2026-06-29" id="Fact000046">false</dei:EntityEmergingGrowthCompany>
    <dei:EntityEmergingGrowthCompany contextRef="AsOf2026-06-29" id="Fact000047">false</dei:EntityEmergingGrowthCompany>
</xbrl>
