<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.24.1.u1</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>166</ContextCount>
  <ElementCount>282</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>false</FootnotesReported>
  <SegmentCount>61</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>9</UnitCount>
  <MyReports>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>00090 - Document - Document and Entity Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DocumentDocumentAndEntityInformation</Role>
      <ShortName>Document and Entity Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>00100 - Statement - Condensed Consolidated Balance Sheets</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedBalanceSheets</Role>
      <ShortName>Condensed Consolidated Balance Sheets</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>00105 - Statement - Condensed Consolidated Balance Sheets (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedBalanceSheetsParenthetical</Role>
      <ShortName>Condensed Consolidated Balance Sheets (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R4.htm</HtmlFileName>
      <LongName>00200 - Statement - Condensed Consolidated Statements of Income (Loss)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedStatementsOfIncomeLoss</Role>
      <ShortName>Condensed Consolidated Statements of Income (Loss)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R5.htm</HtmlFileName>
      <LongName>00300 - Statement - Condensed Consolidated Statements of Comprehensive Income (Loss)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedStatementsOfComprehensiveIncomeLoss</Role>
      <ShortName>Condensed Consolidated Statements of Comprehensive Income (Loss)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>5</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R6.htm</HtmlFileName>
      <LongName>00400 - Statement - Condensed Consolidated Statements of Stockholders' Equity (Deficit)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedStatementsOfStockholdersEquityDeficit</Role>
      <ShortName>Condensed Consolidated Statements of Stockholders' Equity (Deficit)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>6</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R7.htm</HtmlFileName>
      <LongName>00500 - Statement - Condensed Consolidated Statements of Cash Flows</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedStatementsOfCashFlows</Role>
      <ShortName>Condensed Consolidated Statements of Cash Flows</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>7</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R8.htm</HtmlFileName>
      <LongName>00505 - Statement - Condensed Consolidated Statements of Cash Flows (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/StatementCondensedConsolidatedStatementsOfCashFlowsParenthetical</Role>
      <ShortName>Condensed Consolidated Statements of Cash Flows (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>8</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R9.htm</HtmlFileName>
      <LongName>10101 - Disclosure - Nature of Business</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNatureOfBusiness</Role>
      <ShortName>Nature of Business</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>9</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R10.htm</HtmlFileName>
      <LongName>10201 - Disclosure - Summary of Significant Accounting Policies</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureSummaryOfSignificantAccountingPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>10</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R11.htm</HtmlFileName>
      <LongName>10301 - Disclosure - Net Income (Loss) Per Share</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShare</Role>
      <ShortName>Net Income (Loss) Per Share</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>11</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R12.htm</HtmlFileName>
      <LongName>10401 - Disclosure - Collaboration, License, and Other Agreements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreements</Role>
      <ShortName>Collaboration, License, and Other Agreements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>12</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R13.htm</HtmlFileName>
      <LongName>10501 - Disclosure - Fair Value of Financial Instruments</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstruments</Role>
      <ShortName>Fair Value of Financial Instruments</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>13</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R14.htm</HtmlFileName>
      <LongName>10601 - Disclosure - Leases</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeases</Role>
      <ShortName>Leases</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>14</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R15.htm</HtmlFileName>
      <LongName>10701 - Disclosure - Accrued Expenses and Other Current Liabilities</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureAccruedExpensesAndOtherCurrentLiabilities</Role>
      <ShortName>Accrued Expenses and Other Current Liabilities</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>15</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R16.htm</HtmlFileName>
      <LongName>10801 - Disclosure - Debt</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebt</Role>
      <ShortName>Debt</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>16</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R17.htm</HtmlFileName>
      <LongName>10901 - Disclosure - Employee Stock Benefit Plans</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureEmployeeStockBenefitPlans</Role>
      <ShortName>Employee Stock Benefit Plans</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>17</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R18.htm</HtmlFileName>
      <LongName>11001 - Disclosure - Income Taxes</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureIncomeTaxes</Role>
      <ShortName>Income Taxes</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>18</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R19.htm</HtmlFileName>
      <LongName>11101 - Disclosure - Workforce Reduction and Restructuring</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureWorkforceReductionAndRestructuring</Role>
      <ShortName>Workforce Reduction and Restructuring</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>19</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R20.htm</HtmlFileName>
      <LongName>20202 - Disclosure - Summary of Significant Accounting Policies (Policies)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureSummaryOfSignificantAccountingPoliciesPolicies</Role>
      <ShortName>Summary of Significant Accounting Policies (Policies)</ShortName>
      <MenuCategory>Policies</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureSummaryOfSignificantAccountingPolicies</ParentRole>
      <Position>20</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R21.htm</HtmlFileName>
      <LongName>30303 - Disclosure - Net Income (Loss) Per Share (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShareTables</Role>
      <ShortName>Net Income (Loss) Per Share (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShare</ParentRole>
      <Position>21</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R22.htm</HtmlFileName>
      <LongName>30403 - Disclosure - Collaboration, License, and Other Agreements (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsTables</Role>
      <ShortName>Collaboration, License, and Other Agreements (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreements</ParentRole>
      <Position>22</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R23.htm</HtmlFileName>
      <LongName>30503 - Disclosure - Fair Value of Financial Instruments (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstrumentsTables</Role>
      <ShortName>Fair Value of Financial Instruments (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstruments</ParentRole>
      <Position>23</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R24.htm</HtmlFileName>
      <LongName>30603 - Disclosure - Leases (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesTables</Role>
      <ShortName>Leases (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureLeases</ParentRole>
      <Position>24</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R25.htm</HtmlFileName>
      <LongName>30703 - Disclosure - Accrued Expenses and Other Current Liabilities (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureAccruedExpensesAndOtherCurrentLiabilitiesTables</Role>
      <ShortName>Accrued Expenses and Other Current Liabilities (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureAccruedExpensesAndOtherCurrentLiabilities</ParentRole>
      <Position>25</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R26.htm</HtmlFileName>
      <LongName>30803 - Disclosure - Debt (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtTables</Role>
      <ShortName>Debt (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureDebt</ParentRole>
      <Position>26</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R27.htm</HtmlFileName>
      <LongName>30903 - Disclosure - Employee Stock Benefit Plans (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureEmployeeStockBenefitPlansTables</Role>
      <ShortName>Employee Stock Benefit Plans (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureEmployeeStockBenefitPlans</ParentRole>
      <Position>27</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R28.htm</HtmlFileName>
      <LongName>40101 - Disclosure - Nature of Business (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNatureOfBusinessDetails</Role>
      <ShortName>Nature of Business (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureNatureOfBusiness</ParentRole>
      <Position>28</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R29.htm</HtmlFileName>
      <LongName>40301 - Disclosure - Net Income (Loss) Per Share - Computation (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShareComputationDetails</Role>
      <ShortName>Net Income (Loss) Per Share - Computation (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShareTables</ParentRole>
      <Position>29</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R30.htm</HtmlFileName>
      <LongName>40302 - Disclosure - Net Income (Loss) Per Share - Potentially Dilutive Securities (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerSharePotentiallyDilutiveSecuritiesDetails</Role>
      <ShortName>Net Income (Loss) Per Share - Potentially Dilutive Securities (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureNetIncomeLossPerShareTables</ParentRole>
      <Position>30</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R31.htm</HtmlFileName>
      <LongName>40401 - Disclosure - Collaboration, License, and Other Agreements - Summary (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsSummaryDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - Summary (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsTables</ParentRole>
      <Position>31</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R32.htm</HtmlFileName>
      <LongName>40402 - Disclosure - Collaboration, License, and Other Agreements - Accounts Receivable (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsAccountsReceivableDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - Accounts Receivable (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>32</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R33.htm</HtmlFileName>
      <LongName>40403 - Disclosure - Collaboration, License, and Other Agreements - North America - General Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsNorthAmericaGeneralInformationDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - North America - General Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>33</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R34.htm</HtmlFileName>
      <LongName>40404 - Disclosure - Collaboration, License, and Other Agreements - North America - Collaborative Arrangements Revenue (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsNorthAmericaCollaborativeArrangementsRevenueDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - North America - Collaborative Arrangements Revenue (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>34</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R35.htm</HtmlFileName>
      <LongName>40405 - Disclosure - Collaboration, License, and Other Agreements - North America - Commercial Efforts (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsNorthAmericaCommercialEffortsDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - North America - Commercial Efforts (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>35</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R36.htm</HtmlFileName>
      <LongName>40406 - Disclosure - Collaboration, License, and Other Agreements - North America - Royalty Revenue (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsNorthAmericaRoyaltyRevenueDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - North America - Royalty Revenue (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>36</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R37.htm</HtmlFileName>
      <LongName>40407 - Disclosure - Collaboration, License, and Other Agreements - European and Other Territories (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsEuropeanAndOtherTerritoriesDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - European and Other Territories (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>37</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R38.htm</HtmlFileName>
      <LongName>40408 - Disclosure - Collaboration, License, and Other Agreements - Japan (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsJapanDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - Japan (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsTables</ParentRole>
      <Position>38</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R39.htm</HtmlFileName>
      <LongName>40409 - Disclosure - Collaboration, License, and Other Agreements - China, Hong Kong and Macau (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsChinaHongKongAndMacauDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - China, Hong Kong and Macau (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>39</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R40.htm</HtmlFileName>
      <LongName>40410 - Disclosure - Collaboration, License, and Other Agreements - Other Collaboration and License Agreements (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureCollaborationLicenseAndOtherAgreementsOtherCollaborationAndLicenseAgreementsDetails</Role>
      <ShortName>Collaboration, License, and Other Agreements - Other Collaboration and License Agreements (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>40</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R41.htm</HtmlFileName>
      <LongName>40501 - Disclosure - Fair Value of Financial Instruments - General Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstrumentsGeneralInformationDetails</Role>
      <ShortName>Fair Value of Financial Instruments - General Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>41</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R42.htm</HtmlFileName>
      <LongName>40502 - Disclosure - Fair Value of Financial Instruments - Measured on Recurring Basis (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstrumentsMeasuredOnRecurringBasisDetails</Role>
      <ShortName>Fair Value of Financial Instruments - Measured on Recurring Basis (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>42</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R43.htm</HtmlFileName>
      <LongName>40503 - Disclosure - Fair Value of Financial Instruments - Convertible Senior Notes (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstrumentsConvertibleSeniorNotesDetails</Role>
      <ShortName>Fair Value of Financial Instruments - Convertible Senior Notes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>43</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R44.htm</HtmlFileName>
      <LongName>40504 - Disclosure - Fair Value of Financial Instruments - Capped Calls (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureFairValueOfFinancialInstrumentsCappedCallsDetails</Role>
      <ShortName>Fair Value of Financial Instruments - Capped Calls (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>44</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R45.htm</HtmlFileName>
      <LongName>40601 - Disclosure - Leases - Letters of Credit (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesLettersOfCreditDetails</Role>
      <ShortName>Leases - Letters of Credit (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>45</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R46.htm</HtmlFileName>
      <LongName>40602 - Disclosure - Leases - Lease Cost (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesLeaseCostDetails</Role>
      <ShortName>Leases - Lease Cost (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>46</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R47.htm</HtmlFileName>
      <LongName>40603 - Disclosure - Leases - Supplemental Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesSupplementalInformationDetails</Role>
      <ShortName>Leases - Supplemental Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>47</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R48.htm</HtmlFileName>
      <LongName>40604 - Disclosure - Leases - Summer Street Lease (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesSummerStreetLeaseDetails</Role>
      <ShortName>Leases - Summer Street Lease (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>48</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R49.htm</HtmlFileName>
      <LongName>40605 - Disclosure - Leases - Future Minimum Lease Payments (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesFutureMinimumLeasePaymentsDetails</Role>
      <ShortName>Leases - Future Minimum Lease Payments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>49</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R50.htm</HtmlFileName>
      <LongName>40606 - Disclosure - Leases - Operating Lease Obligations (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureLeasesOperatingLeaseObligationsDetails</Role>
      <ShortName>Leases - Operating Lease Obligations (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>50</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R51.htm</HtmlFileName>
      <LongName>40701 - Disclosure - Accrued Expenses and Other Current Liabilities - Tabular Disclosure (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureAccruedExpensesAndOtherCurrentLiabilitiesTabularDisclosureDetails</Role>
      <ShortName>Accrued Expenses and Other Current Liabilities - Tabular Disclosure (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>51</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R52.htm</HtmlFileName>
      <LongName>40702 - Disclosure - Accrued Expenses and Other Current Liabilities - Additional Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureAccruedExpensesAndOtherCurrentLiabilitiesAdditionalInformationDetails</Role>
      <ShortName>Accrued Expenses and Other Current Liabilities - Additional Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>52</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R53.htm</HtmlFileName>
      <LongName>40801 - Disclosure - Debt - General Information (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtGeneralInformationDetails</Role>
      <ShortName>Debt - General Information (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>53</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R54.htm</HtmlFileName>
      <LongName>40802 - Disclosure - Debt - Interest Expense (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtInterestExpenseDetails</Role>
      <ShortName>Debt - Interest Expense (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>54</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R55.htm</HtmlFileName>
      <LongName>40803 - Disclosure - Debt - Convertible Senior Notes - Balances (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtConvertibleSeniorNotesBalancesDetails</Role>
      <ShortName>Debt - Convertible Senior Notes - Balances (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>55</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R56.htm</HtmlFileName>
      <LongName>40804 - Disclosure - Debt - Convertible Senior Notes - Future Minimum Payments (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtConvertibleSeniorNotesFutureMinimumPaymentsDetails</Role>
      <ShortName>Debt - Convertible Senior Notes - Future Minimum Payments (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>56</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R57.htm</HtmlFileName>
      <LongName>40805 - Disclosure - Debt - Convertible Senior Notes Due 2024 and Convertible Senior Notes Due 2026 (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtConvertibleSeniorNotesDue2024AndConvertibleSeniorNotesDue2026Details</Role>
      <ShortName>Debt - Convertible Senior Notes Due 2024 and Convertible Senior Notes Due 2026 (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>57</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R58.htm</HtmlFileName>
      <LongName>40806 - Disclosure - Debt - Convertible Senior Notes Due 2022, Convertible Senior Notes Due 2024 and Convertible Senior Notes Due 2026 (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtConvertibleSeniorNotesDue2022ConvertibleSeniorNotesDue2024AndConvertibleSeniorNotesDue2026Details</Role>
      <ShortName>Debt - Convertible Senior Notes Due 2022, Convertible Senior Notes Due 2024 and Convertible Senior Notes Due 2026 (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>58</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R59.htm</HtmlFileName>
      <LongName>40807 - Disclosure - Debt - Capped Calls with Respect to 2024 Convertible Notes and 2026 Convertible Notes (Details)</LongName>
      <ReportType>Notes</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureDebtCappedCallsWithRespectTo2024ConvertibleNotesAnd2026ConvertibleNotesDetails</Role>
      <ShortName>Debt - Capped Calls with Respect to 2024 Convertible Notes and 2026 Convertible Notes (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>59</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R60.htm</HtmlFileName>
      <LongName>40901 - Disclosure - Employee Stock Benefit Plans (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureEmployeeStockBenefitPlansDetails</Role>
      <ShortName>Employee Stock Benefit Plans (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureEmployeeStockBenefitPlansTables</ParentRole>
      <Position>60</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R61.htm</HtmlFileName>
      <LongName>41001 - Disclosure - Income Taxes - Income Tax Expense (Benefit) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureIncomeTaxesIncomeTaxExpenseBenefitDetails</Role>
      <ShortName>Income Taxes - Income Tax Expense (Benefit) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>61</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R62.htm</HtmlFileName>
      <LongName>41101 - Disclosure - Workforce Reduction and Restructuring (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.ironwoodpharma.com/role/DisclosureWorkforceReductionAndRestructuringDetails</Role>
      <ShortName>Workforce Reduction and Restructuring (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.ironwoodpharma.com/role/DisclosureWorkforceReductionAndRestructuring</ParentRole>
      <Position>62</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R63.htm</HtmlFileName>
      <LongName>995410 - Disclosure - Pay vs Performance Disclosure</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/PvpDisclosure</Role>
      <ShortName>Pay vs Performance Disclosure</ShortName>
      <MenuCategory>Uncategorized</MenuCategory>
      <Position>63</Position>
    </Report>
    <Report instance="irwd-20240331x10q.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R64.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>Cover</MenuCategory>
      <Position>64</Position>
    </Report>
    <Report>
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <LongName>All Reports</LongName>
      <ReportType>Book</ReportType>
      <ShortName>All Reports</ShortName>
    </Report>
  </MyReports>
  <Logs>
    <Log type="Warning">[ix-0514-Hidden-Fact-Eligible-For-Transform] WARN: 2 fact(s) appearing in ix:hidden were eligible for transformation: us-gaap:DebtInstrumentBasisSpreadOnVariableRate1, us-gaap:LongTermDebtTerm -  irwd-20240331x10q.htm 9</Log>
    <Log type="Warning">[ix-0514-Hidden-Fact-Not-Referenced] WARN: 5 fact(s) appearing in ix:hidden were not referenced by any -sec-ix-hidden style property: us-gaap:CommitmentsAndContingencies, us-gaap:RevenueFromContractWithCustomerProductAndServiceExtensibleList -  irwd-20240331x10q.htm 9</Log>
    <Log type="Warning">[dq-0712-Presentation-Base-Set-Order] Role '41101 - Disclosure - Workforce Reduction and Restructuring (Details)', a level 4, Detail role, appears before '995410 - Disclosure - Pay vs Performance Disclosure', a level 1, Note role. https://xbrl.sec.gov/ecd/2023/ecd-2023.xsd 30, irwd-20240331.xsd 315</Log>
  </Logs>
  <InputFiles>
    <File>irwd-20240331.xsd</File>
    <File>irwd-20240331_cal.xml</File>
    <File>irwd-20240331_def.xml</File>
    <File>irwd-20240331_lab.xml</File>
    <File>irwd-20240331_pre.xml</File>
    <File doctype="10-Q" isDefinitelyFs="true" isUsgaap="true" original="irwd-20240331x10q.htm">irwd-20240331x10q.htm</File>
  </InputFiles>
  <SupplementalFiles/>
  <BaseTaxonomies>
    <BaseTaxonomy items="446">http://fasb.org/us-gaap/2023</BaseTaxonomy>
    <BaseTaxonomy items="31">http://xbrl.sec.gov/dei/2023</BaseTaxonomy>
    <BaseTaxonomy items="6">http://xbrl.sec.gov/ecd/2023</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>true</HasCalculationLinkbase>
</FilingSummary>
