v3.20.1

Revenue from Contract with Customers (Disaggregated Revenue) (Details) - USD ($) $ in Thousands | 12 Months Ended
--- | ---
Dec. 31, 2019 | Dec. 31, 2018 | Dec. 31, 2017
Disaggregation of Revenue [Line Items] |  |  |
Revenues | $ 2,727,912 | $ 2,826,573 | $ 2,507,661
Operating Leases, Income Statement, Lease Revenue |  | 88,304 |
Operating Leases, Income Statement, Lease Revenue | 101,072 |  |
Unrealized Gain (Loss) on Derivatives | (72,562) | 85,011 |
Revenue from Related Parties | 21,190 | 20,365 |
Revenue from Contract with Customer, Excluding Assessed Tax | 2,678,212 | 2,632,893 |
Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 1,970,630 | 1,878,988 | 1,731,775
Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 736,092 | 927,220 | 758,206
Product and Service, Other [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 21,190 | 20,365 | 17,680
Transferred over Time [Member] | Transportation [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 1,122,176 | 1,086,956 |
Transferred over Time [Member] | Terminalling [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 202,830 | 189,013 |
Transferred over Time [Member] | Storage [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 376,121 | 352,442 |
Transferred over Time [Member] | Ancillary Services [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 168,431 | 162,273 |
Transferred over Time [Member] | Lease Revenue [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 101,072 | 88,304 |
Transferred over Time [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 1,970,630 | 1,878,988 |
Transferred at Point in Time [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 736,092 | 927,220 |
Operating Segments [Member] | Refined Products Segment [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 2,070,213 | 2,202,602 | 1,987,895
Operating Leases, Income Statement, Lease Revenue |  | 27,706 |
Operating Leases, Income Statement, Lease Revenue | 27,889 |  |
Unrealized Gain (Loss) on Derivatives | (69,538) | 85,643 |
Revenue from Related Parties | 6,719 | 5,533 |
Revenue from Contract with Customer, Excluding Assessed Tax | 2,105,143 | 2,083,720 |
Operating Segments [Member] | Refined Products Segment [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 1,355,682 | 1,316,616 | 1,261,012
Operating Segments [Member] | Refined Products Segment [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 707,812 | 880,453 | 723,153
Operating Segments [Member] | Refined Products Segment [Member] | Product and Service, Other [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 6,719 | 5,533 | 3,730
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Transportation [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 778,394 | 749,266 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Terminalling [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 185,008 | 182,648 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Storage [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 224,336 | 220,874 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Ancillary Services [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 140,055 | 136,122 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Lease Revenue [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 27,889 | 27,706 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred over Time [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 1,355,682 | 1,316,616 |
Operating Segments [Member] | Refined Products Segment [Member] | Transferred at Point in Time [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 707,812 | 880,453 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 663,116 | 627,662 | 523,169
Operating Leases, Income Statement, Lease Revenue |  | 60,598 |
Operating Leases, Income Statement, Lease Revenue | 73,183 |  |
Unrealized Gain (Loss) on Derivatives | (3,024) | (632) |
Revenue from Related Parties | 14,471 | 14,832 |
Revenue from Contract with Customer, Excluding Assessed Tax | 578,486 | 552,864 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 620,365 | 566,063 | 474,166
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 28,280 | 46,767 | 35,053
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Product and Service, Other [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 14,471 | 14,832 | 13,950
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Transportation [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 343,782 | 337,690 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Terminalling [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 17,822 | 6,365 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Storage [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 157,202 | 135,259 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Ancillary Services [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 28,376 | 26,151 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Lease Revenue [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 73,183 | 60,598 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred over Time [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 620,365 | 566,063 |
Operating Segments [Member] | Crude Oil Pipeline and Terminals Segment [Member] | Transferred at Point in Time [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 28,280 | 46,767 |
Intersegment Eliminations [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | (5,417) | (3,691) | (3,403)
Operating Leases, Income Statement, Lease Revenue |  | 0 |
Operating Leases, Income Statement, Lease Revenue | 0 |  |
Unrealized Gain (Loss) on Derivatives | 0 | 0 |
Revenue from Related Parties | 0 | 0 |
Revenue from Contract with Customer, Excluding Assessed Tax | (5,417) | (3,691) |
Intersegment Eliminations [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | (5,417) | (3,691) | (3,403)
Intersegment Eliminations [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 | 0
Intersegment Eliminations [Member] | Product and Service, Other [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 | $ 0
Intersegment Eliminations [Member] | Transferred over Time [Member] | Transportation [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 |
Intersegment Eliminations [Member] | Transferred over Time [Member] | Terminalling [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 |
Intersegment Eliminations [Member] | Transferred over Time [Member] | Storage [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | (5,417) | (3,691) |
Intersegment Eliminations [Member] | Transferred over Time [Member] | Ancillary Services [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 |
Intersegment Eliminations [Member] | Transferred over Time [Member] | Lease Revenue [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | 0 | 0 |
Intersegment Eliminations [Member] | Transferred over Time [Member] | Service [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | (5,417) | (3,691) |
Intersegment Eliminations [Member] | Transferred at Point in Time [Member] | Product [Member] |  |  |
Disaggregation of Revenue [Line Items] |  |  |
Revenues | $ 0 | $ 0 |

X
- Definition Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table. + References No definition available. + Details
Name: | us-gaap_DisaggregationOfRevenueLineItems
Namespace Prefix: | us-gaap_
Data Type: | xbrli:stringItemType
Balance Type: | na
Period Type: | duration

X
- Definition Amount of operating lease income from lease payments and variable lease payments paid and payable to lessor. Includes, but is not limited to, variable lease payments not included in measurement of lease receivable. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 842 -SubTopic 30 -Section 50 -Paragraph 5 -URI http://asc.fasb.org/extlink&oid=119202524&loc=SL77919372-209981 Reference 2: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 842 -SubTopic 30 -Section 45 -Paragraph 3 -URI http://asc.fasb.org/extlink&oid=77888421&loc=SL77919311-209978 Reference 3: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 270 -SubTopic 10 -Section 50 -Paragraph 6A -URI http://asc.fasb.org/extlink&oid=118952077&loc=SL77927221-108306 + Details
Name: | us-gaap_OperatingLeaseLeaseIncome
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition The total amount of revenue recognized for the period from operating leases, including minimum lease revenue, contingent revenue, percentage revenue and sublease revenue. + References Reference 1: http://fasb.org/us-gaap/role/ref/otherTransitionRef -Publisher FASB -Name Accounting Standards Codification -Topic 840 -SubTopic 20 -Section 25 -Paragraph 1 -URI http://asc.fasb.org/extlink&oid=77902458&loc=d3e39896-112707 + Details
Name: | us-gaap_OperatingLeasesIncomeStatementLeaseRevenue
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition Amount, excluding tax collected from customer, of revenue from satisfaction of performance obligation by transferring promised good or service to customer. Tax collected from customer is tax assessed by governmental authority that is both imposed on and concurrent with specific revenue-producing transaction, including, but not limited to, sales, use, value added and excise. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 606 -SubTopic 10 -Section 50 -Paragraph 4 -Subparagraph (a) -URI http://asc.fasb.org/extlink&oid=118956577&loc=SL49130543-203045 Reference 2: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 606 -SubTopic 10 -Section 50 -Paragraph 5 -URI http://asc.fasb.org/extlink&oid=118956577&loc=SL49130545-203045 + Details
Name: | us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition Amount of revenue, fees and commissions earned from transactions between (a) a parent company and its subsidiaries; (b) subsidiaries of a common parent; (c) an entity and trusts for the benefit of employees, for example, but not limited to, pension and profit-sharing trusts that are managed by or under the trusteeship of the entity's management; (d) an entity and its principal, owners, management, or members of their immediate families; and (e) affiliates. + References Reference 1: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 946 -SubTopic 220 -Section S99 -Paragraph 1 -Subparagraph (SX 210.6-07.1(c)) -URI http://asc.fasb.org/extlink&oid=116637345&loc=SL114874292-224272 Reference 2: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 220 -SubTopic 10 -Section S99 -Paragraph 2 -Subparagraph (SX 210.5-03.1(e)) -URI http://asc.fasb.org/extlink&oid=116634182&loc=SL114868664-224227 + Details
Name: | us-gaap_RevenueFromRelatedParties
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition Amount of revenue recognized from goods sold, services rendered, insurance premiums, or other activities that constitute an earning process. Includes, but is not limited to, investment and interest income before deduction of interest expense when recognized as a component of revenue, and sales and trading gain (loss). + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 280 -SubTopic 10 -Section 50 -Paragraph 22 -Subparagraph (a) -URI http://asc.fasb.org/extlink&oid=115929826&loc=d3e8736-108599 Reference 2: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 280 -SubTopic 10 -Section 50 -Paragraph 32 -Subparagraph (a) -URI http://asc.fasb.org/extlink&oid=115929826&loc=d3e8933-108599 Reference 3: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 280 -SubTopic 10 -Section 50 -Paragraph 22 -Subparagraph (b) -URI http://asc.fasb.org/extlink&oid=115929826&loc=d3e8736-108599 Reference 4: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 220 -SubTopic 10 -Section S99 -Paragraph 2 -Subparagraph (SX 210.5-03(1)) -URI http://asc.fasb.org/extlink&oid=116634182&loc=SL114868664-224227 + Details
Name: | us-gaap_Revenues
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition The net change in the difference between the fair value and the carrying value, or in the comparative fair values, of derivative instruments, including options, swaps, futures, and forward contracts, held at each balance sheet date, that was included in earnings for the period. + References Reference 1: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 230 -SubTopic 10 -Section 45 -Paragraph 28 -Subparagraph (b) -URI http://asc.fasb.org/extlink&oid=118932676&loc=d3e3602-108585 + Details
Name: | us-gaap_UnrealizedGainLossOnDerivatives
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Details
Name: | srt_ProductOrServiceAxis=us-gaap_ServiceMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=us-gaap_ProductMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=us-gaap_ProductAndServiceOtherMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_TimingOfTransferOfGoodOrServiceAxis=us-gaap_TransferredOverTimeMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=mmp_TransportationMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=mmp_TerminallingMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=mmp_StorageMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=mmp_AncillaryServicesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ProductOrServiceAxis=mmp_LeaseRevenueMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_TimingOfTransferOfGoodOrServiceAxis=us-gaap_TransferredAtPointInTimeMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ConsolidationItemsAxis=us-gaap_OperatingSegmentsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_StatementBusinessSegmentsAxis=mmp_RefinedProductsSegmentMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_StatementBusinessSegmentsAxis=mmp_CrudeOilPipelineandTerminalsSegmentMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_ConsolidationItemsAxis=us-gaap_IntersegmentEliminationMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |