{
 "instance": {
  "cdxs-20210930.htm": {
   "axisCustom": 1,
   "axisStandard": 34,
   "contextCount": 353,
   "dts": {
    "calculationLink": {
     "local": [
      "cdxs-20210930_cal.xml"
     ]
    },
    "definitionLink": {
     "local": [
      "cdxs-20210930_def.xml"
     ]
    },
    "inline": {
     "local": [
      "cdxs-20210930.htm"
     ]
    },
    "labelLink": {
     "local": [
      "cdxs-20210930_lab.xml"
     ]
    },
    "presentationLink": {
     "local": [
      "cdxs-20210930_pre.xml"
     ]
    },
    "schema": {
     "local": [
      "cdxs-20210930.xsd"
     ],
     "remote": [
      "https://xbrl.fasb.org/srt/2021/elts/srt-2021-01-31.xsd",
      "http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xl-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xlink-2003-12-31.xsd",
      "https://www.xbrl.org/dtr/type/2020-01-21/types.xsd",
      "https://www.xbrl.org/2020/extensible-enumerations-2.0.xsd",
      "http://www.xbrl.org/2005/xbrldt-2005.xsd",
      "http://www.xbrl.org/2006/ref-2006-02-27.xsd",
      "https://xbrl.fasb.org/srt/2021/elts/srt-types-2021-01-31.xsd",
      "https://xbrl.sec.gov/country/2021/country-2021.xsd",
      "https://xbrl.fasb.org/srt/2021/elts/srt-roles-2021-01-31.xsd",
      "https://xbrl.fasb.org/us-gaap/2021/elts/us-gaap-2021-01-31.xsd",
      "https://xbrl.fasb.org/us-gaap/2021/elts/us-types-2021-01-31.xsd",
      "https://xbrl.fasb.org/us-gaap/2021/elts/us-roles-2021-01-31.xsd",
      "https://xbrl.sec.gov/dei/2021/dei-2021.xsd",
      "http://www.xbrl.org/lrr/role/negated-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/net-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/reference-2009-12-16.xsd"
     ]
    }
   },
   "elementCount": 511,
   "entityCount": 1,
   "hidden": {
    "http://fasb.org/us-gaap/2021-01-31": 12,
    "http://xbrl.sec.gov/dei/2021": 5,
    "total": 17
   },
   "keyCustom": 20,
   "keyStandard": 323,
   "memberCustom": 42,
   "memberStandard": 47,
   "nsprefix": "cdxs",
   "nsuri": "http://www.codexis.com/20210930",
   "report": {
    "R1": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "dei:DocumentType",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "document",
     "isDefault": "true",
     "longName": "0001001 - Document - Cover Page",
     "role": "http://www.codexis.com/role/CoverPage",
     "shortName": "Cover Page",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "dei:DocumentType",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R10": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:EarningsPerShareTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2112104 - Disclosure - Net Income (loss) per Share",
     "role": "http://www.codexis.com/role/NetIncomelossperShare",
     "shortName": "Net Income (loss) per Share",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:EarningsPerShareTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R11": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentsInDebtAndEquityInstrumentsCashAndCashEquivalentsUnrealizedAndRealizedGainsLossesTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2116105 - Disclosure - Investments in Non-Marketable Securities",
     "role": "http://www.codexis.com/role/InvestmentsinNonMarketableSecurities",
     "shortName": "Investments in Non-Marketable Securities",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentsInDebtAndEquityInstrumentsCashAndCashEquivalentsUnrealizedAndRealizedGainsLossesTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R12": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueMeasurementInputsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2120106 - Disclosure - Fair Value Measurements",
     "role": "http://www.codexis.com/role/FairValueMeasurements",
     "shortName": "Fair Value Measurements",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueMeasurementInputsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R13": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "cdxs:BalanceSheetsDetailsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2123107 - Disclosure - Balance Sheets Details",
     "role": "http://www.codexis.com/role/BalanceSheetsDetails",
     "shortName": "Balance Sheets Details",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "cdxs:BalanceSheetsDetailsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R14": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2130108 - Disclosure - Stock-based Compensation",
     "role": "http://www.codexis.com/role/StockbasedCompensation",
     "shortName": "Stock-based Compensation",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R15": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:StockholdersEquityNoteDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2137109 - Disclosure - Capital Stock",
     "role": "http://www.codexis.com/role/CapitalStock",
     "shortName": "Capital Stock",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:StockholdersEquityNoteDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R16": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CommitmentsAndContingenciesDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2139110 - Disclosure - Commitments and Contingencies",
     "role": "http://www.codexis.com/role/CommitmentsandContingencies",
     "shortName": "Commitments and Contingencies",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CommitmentsAndContingenciesDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R17": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RelatedPartyTransactionsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2148111 - Disclosure - Related Party Transactions",
     "role": "http://www.codexis.com/role/RelatedPartyTransactions",
     "shortName": "Related Party Transactions",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RelatedPartyTransactionsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R18": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SegmentReportingDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2151112 - Disclosure - Segment, Geographical and Other Revenue Information",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformation",
     "shortName": "Segment, Geographical and Other Revenue Information",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SegmentReportingDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R19": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CreditLossFinancialInstrumentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2159113 - Disclosure - Allowance for Credit Losses",
     "role": "http://www.codexis.com/role/AllowanceforCreditLosses",
     "shortName": "Allowance for Credit Losses",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CreditLossFinancialInstrumentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R2": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CashAndCashEquivalentsAtCarryingValue",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "statement",
     "isDefault": "false",
     "longName": "1001002 - Statement - Condensed Consolidated Balance Sheets (Unaudited)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
     "shortName": "Condensed Consolidated Balance Sheets (Unaudited)",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RestrictedCash",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R20": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:BasisOfAccountingPolicyPolicyTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2204201 - Disclosure - Basis of Presentation and Summary of Significant Accounting Policies (Policies)",
     "role": "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies",
     "shortName": "Basis of Presentation and Summary of Significant Accounting Policies (Policies)",
     "subGroupType": "policies",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:BasisOfAccountingPolicyPolicyTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R21": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisaggregationOfRevenueTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2306301 - Disclosure - Revenue Recognition (Tables)",
     "role": "http://www.codexis.com/role/RevenueRecognitionTables",
     "shortName": "Revenue Recognition (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisaggregationOfRevenueTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R22": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEarningsPerShareBasicAndDilutedTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2313302 - Disclosure - Net Income (loss) per Share (Tables)",
     "role": "http://www.codexis.com/role/NetIncomelossperShareTables",
     "shortName": "Net Income (loss) per Share (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEarningsPerShareBasicAndDilutedTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R23": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2317303 - Disclosure - Investments in Non-Marketable Securities (Tables)",
     "role": "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTables",
     "shortName": "Investments in Non-Marketable Securities (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R24": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2321304 - Disclosure - Fair Value Measurements (Tables)",
     "role": "http://www.codexis.com/role/FairValueMeasurementsTables",
     "shortName": "Fair Value Measurements (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R25": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfCashAndCashEquivalentsTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2324305 - Disclosure - Balance Sheets Details (Tables)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsTables",
     "shortName": "Balance Sheets Details (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfCashAndCashEquivalentsTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R26": {
     "firstAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2331306 - Disclosure - Stock-based Compensation (Tables)",
     "role": "http://www.codexis.com/role/StockbasedCompensationTables",
     "shortName": "Stock-based Compensation (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R27": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LeaseCostTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2340307 - Disclosure - Commitments and Contingencies (Tables)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesTables",
     "shortName": "Commitments and Contingencies (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LeaseCostTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R28": {
     "firstAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2352308 - Disclosure - Segment, Geographical and Other Revenue Information (Tables)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables",
     "shortName": "Segment, Geographical and Other Revenue Information (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R29": {
     "firstAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2360309 - Disclosure - Allowance for Credit Losses (Tables)",
     "role": "http://www.codexis.com/role/AllowanceforCreditLossesTables",
     "shortName": "Allowance for Credit Losses (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R3": {
     "firstAnchor": {
      "ancestors": [
       "us-gaap:PreferredStockParOrStatedValuePerShare",
       "span",
       "div",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PreferredStockParOrStatedValuePerShare",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usdPerShare",
      "xsiNil": "false"
     },
     "groupType": "statement",
     "isDefault": "false",
     "longName": "1002003 - Statement - Condensed Consolidated Balance Sheets (Unaudited) (Parenthetical)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical",
     "shortName": "Condensed Consolidated Balance Sheets (Unaudited) (Parenthetical)",
     "subGroupType": "parenthetical",
     "uniqueAnchor": {
      "ancestors": [
       "us-gaap:PreferredStockParOrStatedValuePerShare",
       "span",
       "div",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PreferredStockParOrStatedValuePerShare",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usdPerShare",
      "xsiNil": "false"
     }
    },
    "R30": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PaymentsToAcquireOtherInvestments",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2402401 - Disclosure - Description of Business (Details)",
     "role": "http://www.codexis.com/role/DescriptionofBusinessDetails",
     "shortName": "Description of Business (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i57a13caa972c460182f96f318a6abe7e_D20200301-20200331",
      "decimals": "-5",
      "lang": "en-US",
      "name": "us-gaap:ProceedsFromCollaborators",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R31": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DisaggregationOfRevenueTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2407402 - Disclosure - Revenue Recognition - Disaggregation of Revenue (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
     "shortName": "Revenue Recognition - Disaggregation of Revenue (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DisaggregationOfRevenueTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i0183c37964cb4450b97ee871573d7958_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R32": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ContractWithCustomerAssetAndLiabilityTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerAssetGrossCurrent",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2408403 - Disclosure - Revenue Recognition - Contracts with Customer (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails",
     "shortName": "Revenue Recognition - Contracts with Customer (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ContractWithCustomerAssetAndLiabilityTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:CapitalizedContractCostNetCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R33": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerAssetCreditLossExpense",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2409404 - Disclosure - Revenue Recognition - Narrative (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionNarrativeDetails",
     "shortName": "Revenue Recognition - Narrative (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerAssetCreditLossExpense",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R34": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "ix:continuation",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiabilityRevenueRecognized",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2410405 - Disclosure - Revenue Recognition - Revenue Recognized During Period (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails",
     "shortName": "Revenue Recognition - Revenue Recognized During Period (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "ix:continuation",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiabilityRevenueRecognized",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R35": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueRemainingPerformanceObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2411406 - Disclosure - Revenue Recognition - Performance Obligation (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
     "shortName": "Revenue Recognition - Performance Obligation (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueRemainingPerformanceObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R36": {
     "firstAnchor": {
      "ancestors": [
       "us-gaap:NetIncomeLoss",
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NetIncomeLoss",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2414407 - Disclosure - Net Income (loss) per Share - Earnings Per Share (Details)",
     "role": "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails",
     "shortName": "Net Income (loss) per Share - Earnings Per Share (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:WeightedAverageNumberDilutedSharesOutstandingAdjustment",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     }
    },
    "R37": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i42e7a3956e1142f78323c0132ac11c9b_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2415408 - Disclosure - Net Income (loss) per Share - Shares Not Included in Computation of Diluted Net Income (Loss) Per Share (Details)",
     "role": "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails",
     "shortName": "Net Income (loss) per Share - Shares Not Included in Computation of Diluted Net Income (Loss) Per Share (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i42e7a3956e1142f78323c0132ac11c9b_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     }
    },
    "R38": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleSecuritiesDebtSecurities",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2418409 - Disclosure - Investments in Non-Marketable Securities - Narrative (Details)",
     "role": "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
     "shortName": "Investments in Non-Marketable Securities - Narrative (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ifd53520ac2544583b4af4d6b446bb812_I20210731",
      "decimals": "-5",
      "lang": "en-US",
      "name": "us-gaap:ConvertibleDebt",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R39": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2419410 - Disclosure - Investments in Non-Marketable Securities - Carrying Value and Fair Value of Securities (Details)",
     "role": "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
     "shortName": "Investments in Non-Marketable Securities - Carrying Value and Fair Value of Securities (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R4": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DisaggregationOfRevenueTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "statement",
     "isDefault": "false",
     "longName": "1003004 - Statement - Condensed Consolidated Statements of Operations (Unaudited)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
     "shortName": "Condensed Consolidated Statements of Operations (Unaudited)",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:InvestmentIncomeInterest",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R40": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleSecuritiesDebtSecurities",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2422411 - Disclosure - Fair Value Measurements (Details)",
     "role": "http://www.codexis.com/role/FairValueMeasurementsDetails",
     "shortName": "Fair Value Measurements (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:AssetsFairValueDisclosure",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R41": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CashAndCashEquivalentsAtCarryingValue",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2425412 - Disclosure - Balance Sheets Details - Cash and Cash Equivalents (Details)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
     "shortName": "Balance Sheets Details - Cash and Cash Equivalents (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ScheduleOfCashAndCashEquivalentsTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "iac477d9a87b3471a89ee0062811a8513_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:CashAndCashEquivalentsAtCarryingValue",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R42": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfInventoryCurrentTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InventoryRawMaterials",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2426413 - Disclosure - Balance Sheets Details - Inventories (Details)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails",
     "shortName": "Balance Sheets Details - Inventories (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfInventoryCurrentTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InventoryRawMaterials",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R43": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:PropertyPlantAndEquipmentTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PropertyPlantAndEquipmentGross",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2427414 - Disclosure - Balance Sheets Details - Property and Equipment, net (Details)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
     "shortName": "Balance Sheets Details - Property and Equipment, net (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:PropertyPlantAndEquipmentTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:PropertyPlantAndEquipmentGross",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R44": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2428415 - Disclosure - Balance Sheets Details - Goodwill (Details)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsGoodwillDetails",
     "shortName": "Balance Sheets Details - Goodwill (Details)",
     "subGroupType": "details",
     "uniqueAnchor": null
    },
    "R45": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfAccruedLiabilitiesTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PurchaseObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2429416 - Disclosure - Balance Sheets Details - Other Accrued Liabilities (Details)",
     "role": "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails",
     "shortName": "Balance Sheets Details - Other Accrued Liabilities (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfAccruedLiabilitiesTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PurchaseObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R46": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ie21662f32f4644f2bbcd0d1cbb50e4e2_I20190422",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2432417 - Disclosure - Stock-based Compensation - Equity Incentive Plans (Details)",
     "role": "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
     "shortName": "Stock-based Compensation - Equity Incentive Plans (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ie21662f32f4644f2bbcd0d1cbb50e4e2_I20190422",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     }
    },
    "R47": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i8758a345de9741b38138fa148d4c3c97_D20210101-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SharebasedCompensationArrangementBySharebasedPaymentAwardPurchasePriceOfCommonStockPercent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2433418 - Disclosure - Stock-based Compensation - Stock Options (Details)",
     "role": "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails",
     "shortName": "Stock-based Compensation - Stock Options (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i8758a345de9741b38138fa148d4c3c97_D20210101-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SharebasedCompensationArrangementBySharebasedPaymentAwardPurchasePriceOfCommonStockPercent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     }
    },
    "R48": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "iec783c0e11fb45bc950a5b7f9852f1c3_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2434419 - Disclosure - Stock-based Compensation - Restricted Stock Units (Details)",
     "role": "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
     "shortName": "Stock-based Compensation - Restricted Stock Units (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "iec783c0e11fb45bc950a5b7f9852f1c3_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R49": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i1b325caee2f943368dc0ebe3ad13ec2a_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "cdxs:SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofInstallments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "installment",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2435420 - Disclosure - Stock-based Compensation - PSUs and PBOs (Details)",
     "role": "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
     "shortName": "Stock-based Compensation - PSUs and PBOs (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i1b325caee2f943368dc0ebe3ad13ec2a_I20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "cdxs:SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofInstallments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "installment",
      "xsiNil": "false"
     }
    },
    "R5": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i639a46100f904800bc33544e75bd3712_I20191231",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SharesOutstanding",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "statement",
     "isDefault": "false",
     "longName": "1004005 - Statement - Condensed Consolidated Statements of Stockholders' Equity (Unaudited)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited",
     "shortName": "Condensed Consolidated Statements of Stockholders' Equity (Unaudited)",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i639a46100f904800bc33544e75bd3712_I20191231",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SharesOutstanding",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     }
    },
    "R50": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfSharebasedCompensationRestrictedStockAndRestrictedStockUnitsActivityTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensation",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2436421 - Disclosure - Stock-based Compensation - Stock-based Compensation Expense (Details)",
     "role": "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails",
     "shortName": "Stock-based Compensation - Stock-based Compensation Expense (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfSharebasedCompensationRestrictedStockAndRestrictedStockUnitsActivityTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i958e628b211544d0ac186f68464310f5_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R51": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:StockIssuedDuringPeriodSharesStockOptionsExercised",
      "reportCount": 1,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2438422 - Disclosure - Capital Stock (Details)",
     "role": "http://www.codexis.com/role/CapitalStockDetails",
     "shortName": "Capital Stock (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "2",
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementsByShareBasedPaymentAwardOptionsExercisesInPeriodWeightedAverageExercisePrice",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usdPerShare",
      "xsiNil": "false"
     }
    },
    "R52": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "0",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AreaOfRealEstateProperty",
      "reportCount": 1,
      "unique": true,
      "unitRef": "sqft",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2441423 - Disclosure - Commitments and Contingencies - Narrative (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails",
     "shortName": "Commitments and Contingencies - Narrative (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "0",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AreaOfRealEstateProperty",
      "reportCount": 1,
      "unique": true,
      "unitRef": "sqft",
      "xsiNil": "false"
     }
    },
    "R53": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FinanceLeaseRightOfUseAssetAmortization",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2442424 - Disclosure - Commitments and Contingencies - Lease Cost (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
     "shortName": "Commitments and Contingencies - Lease Cost (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FinanceLeaseRightOfUseAssetAmortization",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R54": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeaseWeightedAverageRemainingLeaseTerm1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2443425 - Disclosure - Commitments and Contingencies - Other Lease Information (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesOtherLeaseInformationDetails",
     "shortName": "Commitments and Contingencies - Other Lease Information (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeaseWeightedAverageRemainingLeaseTerm1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R55": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeasePayments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2444426 - Disclosure - Commitments and Contingencies - Cash Paid for Lease Obligations (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesCashPaidforLeaseObligationsDetails",
     "shortName": "Commitments and Contingencies - Cash Paid for Lease Obligations (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LeaseCostTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeasePayments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R56": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LesseeOperatingLeaseLiabilityMaturityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2445427 - Disclosure - Commitments and Contingencies - Maturity Analysis of Operating Lease (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails",
     "shortName": "Commitments and Contingencies - Maturity Analysis of Operating Lease (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LesseeOperatingLeaseLiabilityMaturityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityUndiscountedExcessAmount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R57": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:LesseeOperatingLeaseLiabilityMaturityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2446428 - Disclosure - Commitments and Contingencies - Estimated Maturity Analysis (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
     "shortName": "Commitments and Contingencies - Estimated Maturity Analysis (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "ix:continuation",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "idcf9ac935a014e96a4b54ad3b8e6f5dd_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R58": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i3bc40dd294c44dc49b488d81b79b4c2b_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SignificantSupplyCommitmentRemainingMinimumAmountCommitted",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2447429 - Disclosure - Commitments and Contingencies - Other Commitments (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails",
     "shortName": "Commitments and Contingencies - Other Commitments (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i3bc40dd294c44dc49b488d81b79b4c2b_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SignificantSupplyCommitmentRemainingMinimumAmountCommitted",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R59": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PaymentsToAcquireOtherInvestments",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2449430 - Disclosure - Related Party Transactions - Molecular Assemblies, Inc. (Details)",
     "role": "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
     "shortName": "Related Party Transactions - Molecular Assemblies, Inc. (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i83323c1f414a4fefb89f225a14d3473b_I20201231",
      "decimals": "INF",
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiability",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R6": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "ix:continuation",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NetIncomeLoss",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "statement",
     "isDefault": "false",
     "longName": "1005006 - Statement - Condensed Consolidated Statements of Cash Flows (Unaudited)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited",
     "shortName": "Condensed Consolidated Statements of Cash Flows (Unaudited)",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:OperatingLeaseRightOfUseAssetAmortizationExpense",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R60": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AccountsReceivableRelatedParties",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2450431 - Disclosure - Related Party Transactions - AstraZeneca PLC (Details)",
     "role": "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
     "shortName": "Related Party Transactions - AstraZeneca PLC (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib529c5f14d8b40dea18e38e19258f71a_I20201231",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AccountsReceivableRelatedParties",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R61": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "us-gaap:SegmentReportingPolicyPolicyTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NumberOfOperatingSegments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "segment",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2453432 - Disclosure - Segment, Geographical and Other Revenue Information - Narrative (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationNarrativeDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Narrative (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "us-gaap:SegmentReportingPolicyPolicyTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NumberOfOperatingSegments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "segment",
      "xsiNil": "false"
     }
    },
    "R62": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DisaggregationOfRevenueTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2454433 - Disclosure - Segment, Geographical and Other Revenue Information - Segment Reporting (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Segment Reporting (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i18ac02e4ed44466b934278c3430441af_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R63": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:SchedulesOfConcentrationOfRiskByRiskFactorTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ieffed0766d66449ab85ad21c5e4ad85f_D20210701-20210930",
      "decimals": "2",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ConcentrationRiskPercentage1",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2455434 - Disclosure - Segment, Geographical and Other Revenue Information - Concentration Risk (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Concentration Risk (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:SchedulesOfConcentrationOfRiskByRiskFactorTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ieffed0766d66449ab85ad21c5e4ad85f_D20210701-20210930",
      "decimals": "2",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ConcentrationRiskPercentage1",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     }
    },
    "R64": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DisaggregationOfRevenueTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i761a6a4a036d4a0cb7cb244944aaed80_D20210701-20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2456435 - Disclosure - Segment, Geographical and Other Revenue Information - Revenues by Geographic Area (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Revenues by Geographic Area (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ReconciliationOfRevenueFromSegmentsToConsolidatedTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i95a84f7e2c064e24b0ab672717497941_D20210701-20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R65": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "id17270a661d9499c800dffd620fad0e5_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NoncurrentAssets",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2457436 - Disclosure - Segment, Geographical and Other Revenue Information - Long-Lived Assets by Geographic Area (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Long-Lived Assets by Geographic Area (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "id17270a661d9499c800dffd620fad0e5_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NoncurrentAssets",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R66": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2458437 - Disclosure - Segment, Geographical and Other Revenue Information - Goodwill (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Goodwill (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ie2b279b7de12496fa6f8bd3c3f150219_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R67": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForNotesAndLoansReceivableCurrent",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2461438 - Disclosure - Allowance for Credit Losses - Analysis of Allowance for Credit Losses (Details)",
     "role": "http://www.codexis.com/role/AllowanceforCreditLossesAnalysisofAllowanceforCreditLossesDetails",
     "shortName": "Allowance for Credit Losses - Analysis of Allowance for Credit Losses (Details)",
     "subGroupType": "details",
     "uniqueAnchor": null
    },
    "R68": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "i370e656826bb4bd2a18aa8587612a918_I20210930",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AccountsReceivableGrossCurrent",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2462439 - Disclosure - Allowance for Credit Losses - Summary of Finance Receivables by Aging Category (Details)",
     "role": "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails",
     "shortName": "Allowance for Credit Losses - Summary of Finance Receivables by Aging Category (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:PastDueFinancingReceivablesTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ib4de1df070c7496b8d33c0a6cda72ca9_I20210930",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:AccountsReceivableGrossCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R7": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NatureOfOperations",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2101101 - Disclosure - Description of Business",
     "role": "http://www.codexis.com/role/DescriptionofBusiness",
     "shortName": "Description of Business",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NatureOfOperations",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R8": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SignificantAccountingPoliciesTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2103102 - Disclosure - Basis of Presentation and Summary of Significant Accounting Policies",
     "role": "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPolicies",
     "shortName": "Basis of Presentation and Summary of Significant Accounting Policies",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SignificantAccountingPoliciesTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R9": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2105103 - Disclosure - Revenue Recognition",
     "role": "http://www.codexis.com/role/RevenueRecognition",
     "shortName": "Revenue Recognition",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210930.htm",
      "contextRef": "ide307d4123314cf5a8326faee6a99605_D20210101-20210930",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    }
   },
   "segmentCount": 90,
   "tag": {
    "cdxs_A101SaginawMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "101 Saginaw",
        "label": "101 Saginaw [Member]",
        "terseLabel": "101 Saginaw"
       }
      }
     },
     "localname": "A101SaginawMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A200220PenobscotMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "200-220 Penobscot",
        "label": "200-220 Penobscot [Member]",
        "terseLabel": "200-220 Penobscot"
       }
      }
     },
     "localname": "A200220PenobscotMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2019PSUandPBOPlanMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2019 PSU and PBO Plan [Member]",
        "label": "2019 PSU and PBO Plan [Member]",
        "terseLabel": "2019 PSU and PBO"
       }
      }
     },
     "localname": "A2019PSUandPBOPlanMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2019PlanMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2019 Plan [Member]",
        "label": "2019 Plan [Member]",
        "terseLabel": "2019 Plan"
       }
      }
     },
     "localname": "A2019PlanMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2020PBOMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2020 PBO",
        "label": "2020 PBO [Member]",
        "terseLabel": "2020 PBO"
       }
      }
     },
     "localname": "A2020PBOMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2020PSUAndPBOPlanMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2020 PSU and PBO Plan",
        "label": "2020 PSU and PBO Plan [Member]",
        "terseLabel": "2020 PSU and PBO"
       }
      }
     },
     "localname": "A2020PSUAndPBOPlanMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2021PSUMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2021 PSU",
        "label": "2021 PSU [Member]",
        "terseLabel": "2021 PSU"
       }
      }
     },
     "localname": "A2021PSUMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A400PenoscotMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "400 Penoscot",
        "label": "400 Penoscot [Member]",
        "terseLabel": "400 Penobscot"
       }
      }
     },
     "localname": "A400PenoscotMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A501ChesapeakeMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "501 Chesapeake",
        "label": "501 Chesapeake [Member]",
        "terseLabel": "501 Chesapeake"
       }
      }
     },
     "localname": "A501ChesapeakeMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_APACMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Regions of Australia, New Zealand, Southeast Asia and China",
        "label": "APAC [Member]",
        "terseLabel": "APAC"
       }
      }
     },
     "localname": "APACMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_AgreementDateAxis": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Agreement Date [Axis]",
        "label": "Agreement Date [Axis]",
        "terseLabel": "Agreement Date [Axis]"
       }
      }
     },
     "localname": "AgreementDateAxis",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_AgreementDateDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "[Domain] for Agreement Date [Axis]",
        "label": "Agreement Date [Domain]",
        "terseLabel": "Agreement Date [Domain]"
       }
      }
     },
     "localname": "AgreementDateDomain",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_April2016Member": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "April 2016 [Member]",
        "label": "April 2016 [Member]",
        "terseLabel": "April 2016"
       }
      }
     },
     "localname": "April2016Member",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ArzedaCorpMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Arzeda Corp.",
        "label": "Arzeda Corp. [Member]",
        "terseLabel": "Arzeda Corp."
       }
      }
     },
     "localname": "ArzedaCorpMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_BalanceSheetsDetailsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "-- None. No documentation exists for this element. --",
        "label": "Balance Sheets Details [Abstract]",
        "terseLabel": "Balance Sheets Details [Abstract]"
       }
      }
     },
     "localname": "BalanceSheetsDetailsAbstract",
     "nsuri": "http://www.codexis.com/20210930",
     "xbrltype": "stringItemType"
    },
    "cdxs_BalanceSheetsDetailsTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Balance sheets details.",
        "label": "Balance Sheets Details [Text Block]",
        "verboseLabel": "Balance Sheets Details"
       }
      }
     },
     "localname": "BalanceSheetsDetailsTextBlock",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetails"
     ],
     "xbrltype": "textBlockItemType"
    },
    "cdxs_BiotherapeuticSegmentMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Biotherapeutic Segment [Member]",
        "label": "Biotherapeutic Segment [Member]",
        "verboseLabel": "Novel Biotherapeutics"
       }
      }
     },
     "localname": "BiotherapeuticSegmentMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ChangeInContractWithCustomerLiabilityDuringPeriodAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Change In Contract With Customer, Liability, During Period",
        "label": "Change In Contract With Customer, Liability, During Period [Abstract]",
        "terseLabel": "Changes in the period:"
       }
      }
     },
     "localname": "ChangeInContractWithCustomerLiabilityDuringPeriodAbstract",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_CommitmentsAndContingenciesLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Commitments and contingencies.",
        "label": "Commitments and Contingencies [Line Items]",
        "terseLabel": "Commitments and Contingencies [Line Items]"
       }
      }
     },
     "localname": "CommitmentsAndContingenciesLineItems",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_ContractwithCustomerLiabilityNewActivitiesPerformanceObligationSatisfiedRevenueRecognition": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails": {
       "order": 3.0,
       "parentTag": "us-gaap_ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Contract with Customer, Liability, New Activities, Performance Obligation Satisfied, Revenue Recognition",
        "label": "Contract with Customer, Liability, New Activities, Performance Obligation Satisfied, Revenue Recognition",
        "terseLabel": "Performance obligations satisfied from new activities in the period - contract revenue"
       }
      }
     },
     "localname": "ContractwithCustomerLiabilityNewActivitiesPerformanceObligationSatisfiedRevenueRecognition",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_CoreSegmentMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Core Segment [Member]",
        "label": "Core Segment [Member]",
        "verboseLabel": "Performance Enzymes"
       }
      }
     },
     "localname": "CoreSegmentMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerAMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer A [Member]",
        "label": "Customer A [Member]",
        "terseLabel": "Customer A"
       }
      }
     },
     "localname": "CustomerAMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerBMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer B [Member]",
        "label": "Customer B [Member]",
        "terseLabel": "Customer B"
       }
      }
     },
     "localname": "CustomerBMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerCMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer C [Member]",
        "label": "Customer C [Member]",
        "terseLabel": "Customer C"
       }
      }
     },
     "localname": "CustomerCMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerDMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer D [Member]",
        "label": "Customer D [Member]",
        "terseLabel": "Customer D"
       }
      }
     },
     "localname": "CustomerDMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerEMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer E",
        "label": "Customer E [Member]",
        "terseLabel": "Customer E"
       }
      }
     },
     "localname": "CustomerEMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CustomerFMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Customer F",
        "label": "Customer F [Member]",
        "terseLabel": "Customer F"
       }
      }
     },
     "localname": "CustomerFMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_FinanceLeaseCost": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_LeaseCost",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Finance Lease, Cost",
        "label": "Finance Lease, Cost",
        "totalLabel": "Finance lease costs"
       }
      }
     },
     "localname": "FinanceLeaseCost",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_IncentiveStockOptionsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Incentive Stock Options [Member]",
        "label": "Incentive Stock Options [Member]",
        "terseLabel": "Incentive Stock Options"
       }
      }
     },
     "localname": "IncentiveStockOptionsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_IncreaseDecreaseInEmployeeRelatedLiabilitiesAndOtherAccruedLiabilities": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 13.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Increase (Decrease) in Employee Related Liabilities and Other Accrued Liabilities",
        "label": "Increase (Decrease) in Employee Related Liabilities and Other Accrued Liabilities",
        "negatedTerseLabel": "Accrued compensation and other accrued liabilities"
       }
      }
     },
     "localname": "IncreaseDecreaseInEmployeeRelatedLiabilitiesAndOtherAccruedLiabilities",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_LaboratoryEquipmentMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Laboratory Equipment [Member]",
        "label": "Laboratory Equipment [Member]",
        "terseLabel": "Laboratory equipment"
       }
      }
     },
     "localname": "LaboratoryEquipmentMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_LesseeOperatingLeaseLiabilityToBePaidAfterYearFour": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 6.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Lessee, Operating Lease, Liability, to be Paid, After Year Four",
        "label": "Lessee, Operating Lease, Liability, to be Paid, After Year Four",
        "terseLabel": "2026 and thereafter",
        "verboseLabel": "2026 and thereafter"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityToBePaidAfterYearFour",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_LesseeOperatingLeaseOptionToExtendNumber": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Lessee, Operating Lease, Option To Extend, Number",
        "label": "Lessee, Operating Lease, Option To Extend, Number",
        "terseLabel": "Number of options to extend"
       }
      }
     },
     "localname": "LesseeOperatingLeaseOptionToExtendNumber",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "integerItemType"
    },
    "cdxs_MasterCollaborationResearchAgreementMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Master Collaboration &amp; Research Agreement",
        "label": "Master Collaboration &amp; Research Agreement [Member]",
        "terseLabel": "MCRA"
       }
      }
     },
     "localname": "MasterCollaborationResearchAgreementMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_MolecularAssembliesIncMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Molecular Assemblies, Inc.",
        "label": "Molecular Assemblies, Inc. [Member]",
        "terseLabel": "Molecular Assemblies, Inc."
       }
      }
     },
     "localname": "MolecularAssembliesIncMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_NonMarketableDebtSecuritiesWithoutReadilyDeterminableFairValueAnnualAmount": {
     "auth_ref": [],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Non Marketable Debt Securities, Without Readily Determinable Fair Value, Annual Amount",
        "label": "Non Marketable Debt Securities, Without Readily Determinable Fair Value, Annual Amount",
        "terseLabel": "Debt securities, unrealized or realized gains or losses"
       }
      }
     },
     "localname": "NonMarketableDebtSecuritiesWithoutReadilyDeterminableFairValueAnnualAmount",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_NonStatutoryStockOptionsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Non-Statutory Stock Options [Member]",
        "label": "Non-Statutory Stock Options [Member]",
        "terseLabel": "Non-Statutory Stock Options"
       }
      }
     },
     "localname": "NonStatutoryStockOptionsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_NovelBiotherapeuticsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Novel Biotherapeutics [Member]",
        "label": "Novel Biotherapeutics [Member]",
        "terseLabel": "Novel Biotherapeutics"
       }
      }
     },
     "localname": "NovelBiotherapeuticsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_OfficeEquipmentAndFurnitureMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Office Equipment and Furniture [Member]",
        "label": "Office Equipment and Furniture [Member]",
        "terseLabel": "Office equipment and furniture"
       }
      }
     },
     "localname": "OfficeEquipmentAndFurnitureMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_PercentageOfEligibleAccountsReceivable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Percentage Of Eligible Accounts Receivable",
        "label": "Percentage Of Eligible Accounts Receivable",
        "terseLabel": "Percentage of eligible accounts receivable"
       }
      }
     },
     "localname": "PercentageOfEligibleAccountsReceivable",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_PercentofVotingInterestsThresholdtotriggerhigherexerciseprice": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Percent of Voting Interests Threshold to trigger higher exercise price",
        "label": "Percent of Voting Interests Threshold to trigger higher exercise price",
        "terseLabel": "Percent of voting interests"
       }
      }
     },
     "localname": "PercentofVotingInterestsThresholdtotriggerhigherexerciseprice",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_PerformanceBasedOptionsPBOsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Performance Based Options (PBOs) [Member]",
        "label": "Performance Based Options (PBOs) [Member]",
        "verboseLabel": "PBOs"
       }
      }
     },
     "localname": "PerformanceBasedOptionsPBOsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_PerformanceEnzymesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Performance Enzymes [Member]",
        "label": "Performance Enzymes [Member]",
        "terseLabel": "Performance Enzymes"
       }
      }
     },
     "localname": "PerformanceEnzymesMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_PerformanceStockUnitsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Performance Stock Units [Member]",
        "label": "Performance Stock Units [Member]",
        "verboseLabel": "PSUs"
       }
      }
     },
     "localname": "PerformanceStockUnitsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_PiperSandlerCoMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Piper Sandler &amp; Co",
        "label": "Piper Sandler &amp; Co [Member]",
        "terseLabel": "PSC"
       }
      }
     },
     "localname": "PiperSandlerCoMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ProductSalesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Product Sales [Member]",
        "label": "Product Sales [Member]",
        "terseLabel": "Product revenue"
       }
      }
     },
     "localname": "ProductSalesMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_RSAsandRSUsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "RSAs and RSUs [Member]",
        "label": "RSAs and RSUs [Member]",
        "verboseLabel": "RSUs and RSAs"
       }
      }
     },
     "localname": "RSAsandRSUsMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ResearchandDevelopmentRevenueMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Research and Development Revenue [Member]",
        "label": "Research and Development Revenue [Member]",
        "terseLabel": "Research and development revenue"
       }
      }
     },
     "localname": "ResearchandDevelopmentRevenueMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_SaleOfStockCommissionsAndReimbursementsPercentageOfGrossSalesPrice": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sale Of Stock, Commissions And Reimbursements, Percentage Of Gross Sales Price",
        "label": "Sale Of Stock, Commissions And Reimbursements, Percentage Of Gross Sales Price",
        "terseLabel": "Commissions and reimbursements of expenses as percentage of gross sales price"
       }
      }
     },
     "localname": "SaleOfStockCommissionsAndReimbursementsPercentageOfGrossSalesPrice",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_SaleOfStockCommissionsPercentageOfGrossSalesPrice": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sale Of Stock, Commissions, Percentage Of Gross Sales Price",
        "label": "Sale Of Stock, Commissions, Percentage Of Gross Sales Price",
        "terseLabel": "Commissions as percentage of gross sales price"
       }
      }
     },
     "localname": "SaleOfStockCommissionsPercentageOfGrossSalesPrice",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_SaleOfStockPeriod": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sale Of Stock, Period",
        "label": "Sale Of Stock, Period",
        "terseLabel": "Sale period"
       }
      }
     },
     "localname": "SaleOfStockPeriod",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "cdxs_SaleOfStockValueOfSharesForIssuance": {
     "auth_ref": [],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sale Of Stock, Value Of Shares For Issuance",
        "label": "Sale Of Stock, Value Of Shares For Issuance",
        "terseLabel": "Value of shares for issuance"
       }
      }
     },
     "localname": "SaleOfStockValueOfSharesForIssuance",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_SanCarlosCalifiorniaMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "San Carlos, Califiornia",
        "label": "San Carlos, Califiornia [Member]",
        "terseLabel": "San Carlos, Califiornia"
       }
      }
     },
     "localname": "SanCarlosCalifiorniaMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_SanCarlosMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "San Carlos",
        "label": "San Carlos [Member]",
        "terseLabel": "San Carlos"
       }
      }
     },
     "localname": "SanCarlosMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ScheduleOfCommitmentsAndContingenciesLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule of Commitments and Contingencies [Line Items]",
        "label": "Schedule of Commitments and Contingencies [Line Items]",
        "terseLabel": "Schedule of Commitments and Contingencies [Line Items]"
       }
      }
     },
     "localname": "ScheduleOfCommitmentsAndContingenciesLineItems",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_ScheduleOfCommitmentsAndContingenciesTable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule of commitments and contingencies.",
        "label": "Schedule of Commitments and Contingencies [Table]",
        "terseLabel": "Schedule of Commitments and Contingencies [Table]"
       }
      }
     },
     "localname": "ScheduleOfCommitmentsAndContingenciesTable",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_September2019Member": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "September 2019 [Member]",
        "label": "September 2019 [Member]",
        "terseLabel": "September 2019"
       }
      }
     },
     "localname": "September2019Member",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_SeriesB2PreferredStockMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Series B-2 Preferred Stock",
        "label": "Series B-2 Preferred Stock [Member]",
        "terseLabel": "Series B-2 Preferred Stock"
       }
      }
     },
     "localname": "SeriesB2PreferredStockMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ShareBasedCompensationArrangementByShareBasedPaymentAwardExpirationPeriodUponTerminationOfService": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-Based Compensation Arrangement By Share-Based Payment Award, Expiration Period Upon Termination Of Service",
        "label": "Share-Based Compensation Arrangement By Share-Based Payment Award, Expiration Period Upon Termination Of Service",
        "terseLabel": "Expiration period of options upon employee's termination of service"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardExpirationPeriodUponTerminationOfService",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "cdxs_ShareBasedCompensationArrangementByShareBasedPaymentAwardPurchasePriceOfCommonStockAboveMinimumThresholdPercent": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based Compensation Arrangement by Share-based Payment Award, Purchase Price of Common Stock Above Minimum Threshold, Percent",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Purchase Price of Common Stock Above Minimum Threshold, Percent",
        "terseLabel": "Purchase price of common stock above minimum threshold"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardPurchasePriceOfCommonStockAboveMinimumThresholdPercent",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_SharebasedCompensationArrangementbySharebasedPaymentAwardEstimatedPerformanceGoalAchievementRate": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based Compensation Arrangement by Share-based Payment Award, Estimated Performance Goal Achievement Rate",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Estimated Performance Goal Achievement Rate",
        "terseLabel": "Estimated performance goal achievement rate"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementbySharebasedPaymentAwardEstimatedPerformanceGoalAchievementRate",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "cdxs_SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofInstallments": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based Compensation Arrangement by Share-based Payment Award, Number of Installments",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Number of Installments",
        "terseLabel": "Number of installments"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofInstallments",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "integerItemType"
    },
    "cdxs_SharebasedCompensationArrangementbySharebasedPaymentAwardPerformanceAwardsThresholdLevelNumberofSharesMultiplier": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based Compensation Arrangement by Share-based Payment Award, Performance Awards, Threshold Level, Number of Shares, Multiplier",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Performance Awards, Threshold Level, Number of Shares, Multiplier",
        "terseLabel": "Performance awards, threshold level, number of shares, multiplier"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementbySharebasedPaymentAwardPerformanceAwardsThresholdLevelNumberofSharesMultiplier",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "pureItemType"
    },
    "cdxs_SharesReceivedInExchangeForServicesRendered": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Shares Received In Exchange For Services Rendered",
        "label": "Shares Received In Exchange For Services Rendered",
        "terseLabel": "Number of shares received in exchange for services (in shares)"
       }
      }
     },
     "localname": "SharesReceivedInExchangeForServicesRendered",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "cdxs_ShortTermLeaseTerm": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Short-Term Lease, Term",
        "label": "Short-Term Lease, Term",
        "terseLabel": "Short-term lease, term"
       }
      }
     },
     "localname": "ShortTermLeaseTerm",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "cdxs_SubleaseMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sublease",
        "label": "Sublease [Member]",
        "terseLabel": "Sublease"
       }
      }
     },
     "localname": "SubleaseMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_TakedaPharmaceuticalCoLtdMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Takeda Pharmaceutical Co. Ltd.",
        "label": "Takeda Pharmaceutical Co. Ltd. [Member]",
        "terseLabel": "Takeda"
       }
      }
     },
     "localname": "TakedaPharmaceuticalCoLtdMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_TermLoanMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Term Loan [Member]",
        "label": "Term Loan [Member]",
        "terseLabel": "Term Loan"
       }
      }
     },
     "localname": "TermLoanMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_TransactionsWithAstraZenecaPLCMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Transactions With AstraZeneca PLC",
        "label": "Transactions With AstraZeneca PLC [Member]",
        "terseLabel": "Transactions with AstraZeneca PLC"
       }
      }
     },
     "localname": "TransactionsWithAstraZenecaPLCMember",
     "nsuri": "http://www.codexis.com/20210930",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "country_US": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "UNITED STATES",
        "terseLabel": "United States"
       }
      }
     },
     "localname": "US",
     "nsuri": "http://xbrl.sec.gov/country/2021",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "dei_AmendmentFlag": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Boolean flag that is true when the XBRL content amends previously-filed or accepted submission.",
        "label": "Amendment Flag",
        "terseLabel": "Amendment Flag"
       }
      }
     },
     "localname": "AmendmentFlag",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_CityAreaCode": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Area code of city",
        "label": "City Area Code",
        "terseLabel": "City Area Code"
       }
      }
     },
     "localname": "CityAreaCode",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_CoverAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Cover page.",
        "label": "Cover [Abstract]",
        "terseLabel": "Cover page."
       }
      }
     },
     "localname": "CoverAbstract",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "xbrltype": "stringItemType"
    },
    "dei_CurrentFiscalYearEndDate": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "End date of current fiscal year in the format --MM-DD.",
        "label": "Current Fiscal Year End Date",
        "terseLabel": "Current Fiscal Year End Date"
       }
      }
     },
     "localname": "CurrentFiscalYearEndDate",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "gMonthDayItemType"
    },
    "dei_DocumentFiscalPeriodFocus": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Fiscal period values are FY, Q1, Q2, and Q3.  1st, 2nd and 3rd quarter 10-Q or 10-QT statements have value Q1, Q2, and Q3 respectively, with 10-K, 10-KT or other fiscal year statements having FY.",
        "label": "Document Fiscal Period Focus",
        "terseLabel": "Document Fiscal Period Focus"
       }
      }
     },
     "localname": "DocumentFiscalPeriodFocus",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "fiscalPeriodItemType"
    },
    "dei_DocumentFiscalYearFocus": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This is focus fiscal year of the document report in YYYY format. For a 2006 annual report, which may also provide financial information from prior periods, fiscal 2006 should be given as the fiscal year focus. Example: 2006.",
        "label": "Document Fiscal Year Focus",
        "terseLabel": "Document Fiscal Year Focus"
       }
      }
     },
     "localname": "DocumentFiscalYearFocus",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "gYearItemType"
    },
    "dei_DocumentPeriodEndDate": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "For the EDGAR submission types of Form 8-K: the date of the report, the date of the earliest event reported; for the EDGAR submission types of Form N-1A: the filing date; for all other submission types: the end of the reporting or transition period.  The format of the date is YYYY-MM-DD.",
        "label": "Document Period End Date",
        "terseLabel": "Document Period End Date"
       }
      }
     },
     "localname": "DocumentPeriodEndDate",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "dateItemType"
    },
    "dei_DocumentQuarterlyReport": {
     "auth_ref": [
      "r530"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Boolean flag that is true only for a form used as an quarterly report.",
        "label": "Document Quarterly Report",
        "terseLabel": "Document Quarterly Report"
       }
      }
     },
     "localname": "DocumentQuarterlyReport",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_DocumentTransitionReport": {
     "auth_ref": [
      "r531"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Boolean flag that is true only for a form used as a transition report.",
        "label": "Document Transition Report",
        "terseLabel": "Document Transition Report"
       }
      }
     },
     "localname": "DocumentTransitionReport",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_DocumentType": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The type of document being provided (such as 10-K, 10-Q, 485BPOS, etc). The document type is limited to the same value as the supporting SEC submission type, or the word 'Other'.",
        "label": "Document Type",
        "terseLabel": "Document Type"
       }
      }
     },
     "localname": "DocumentType",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "submissionTypeItemType"
    },
    "dei_EntityAddressAddressLine1": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Address Line 1 such as Attn, Building Name, Street Name",
        "label": "Entity Address, Address Line One",
        "terseLabel": "Entity Address, Address Line One"
       }
      }
     },
     "localname": "EntityAddressAddressLine1",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_EntityAddressCityOrTown": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Name of the City or Town",
        "label": "Entity Address, City or Town",
        "terseLabel": "Entity Address, City or Town"
       }
      }
     },
     "localname": "EntityAddressCityOrTown",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_EntityAddressPostalZipCode": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Code for the postal or zip code",
        "label": "Entity Address, Postal Zip Code",
        "terseLabel": "Entity Address, Postal Zip Code"
       }
      }
     },
     "localname": "EntityAddressPostalZipCode",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_EntityAddressStateOrProvince": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Name of the state or province.",
        "label": "Entity Address, State or Province",
        "terseLabel": "Entity Address, State or Province"
       }
      }
     },
     "localname": "EntityAddressStateOrProvince",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "stateOrProvinceItemType"
    },
    "dei_EntityCentralIndexKey": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "A unique 10-digit SEC-issued value to identify entities that have filed disclosures with the SEC. It is commonly abbreviated as CIK.",
        "label": "Entity Central Index Key",
        "terseLabel": "Entity Central Index Key"
       }
      }
     },
     "localname": "EntityCentralIndexKey",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "centralIndexKeyItemType"
    },
    "dei_EntityCommonStockSharesOutstanding": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Indicate number of shares or other units outstanding of each of registrant's classes of capital or common stock or other ownership interests, if and as stated on cover of related periodic report. Where multiple classes or units exist define each class/interest by adding class of stock items such as Common Class A [Member], Common Class B [Member] or Partnership Interest [Member] onto the Instrument [Domain] of the Entity Listings, Instrument.",
        "label": "Entity Common Stock, Shares Outstanding",
        "terseLabel": "Entity Common Stock, Shares Outstanding"
       }
      }
     },
     "localname": "EntityCommonStockSharesOutstanding",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "sharesItemType"
    },
    "dei_EntityCurrentReportingStatus": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Indicate 'Yes' or 'No' whether registrants (1) have filed all reports required to be filed by Section 13 or 15(d) of the Securities Exchange Act of 1934 during the preceding 12 months (or for such shorter period that registrants were required to file such reports), and (2) have been subject to such filing requirements for the past 90 days. This information should be based on the registrant's current or most recent filing containing the related disclosure.",
        "label": "Entity Current Reporting Status",
        "terseLabel": "Entity Current Reporting Status"
       }
      }
     },
     "localname": "EntityCurrentReportingStatus",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "yesNoItemType"
    },
    "dei_EntityDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "All the names of the entities being reported upon in a document. Any legal structure used to conduct activities or to hold assets. Some examples of such structures are corporations, partnerships, limited liability companies, grantor trusts, and other trusts. This item does not include business and geographical segments which are included in the geographical or business segments domains.",
        "label": "Entity [Domain]",
        "terseLabel": "Entity [Domain]"
       }
      }
     },
     "localname": "EntityDomain",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "dei_EntityEmergingGrowthCompany": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Indicate if registrant meets the emerging growth company criteria.",
        "label": "Entity Emerging Growth Company",
        "terseLabel": "Entity Emerging Growth"
       }
      }
     },
     "localname": "EntityEmergingGrowthCompany",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_EntityFileNumber": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Commission file number. The field allows up to 17 characters. The prefix may contain 1-3 digits, the sequence number may contain 1-8 digits, the optional suffix may contain 1-4 characters, and the fields are separated with a hyphen.",
        "label": "Entity File Number",
        "terseLabel": "Entity File Number"
       }
      }
     },
     "localname": "EntityFileNumber",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "fileNumberItemType"
    },
    "dei_EntityFilerCategory": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Indicate whether the registrant is one of the following: Large Accelerated Filer, Accelerated Filer, Non-accelerated Filer. Definitions of these categories are stated in Rule 12b-2 of the Exchange Act. This information should be based on the registrant's current or most recent filing containing the related disclosure.",
        "label": "Entity Filer Category",
        "terseLabel": "Entity Filer Category"
       }
      }
     },
     "localname": "EntityFilerCategory",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "filerCategoryItemType"
    },
    "dei_EntityIncorporationStateCountryCode": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Two-character EDGAR code representing the state or country of incorporation.",
        "label": "Entity Incorporation, State or Country Code",
        "terseLabel": "Entity Incorporation, State or Country Code"
       }
      }
     },
     "localname": "EntityIncorporationStateCountryCode",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "edgarStateCountryItemType"
    },
    "dei_EntityInteractiveDataCurrent": {
     "auth_ref": [
      "r555"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Boolean flag that is true when the registrant has submitted electronically every Interactive Data File required to be submitted pursuant to Rule 405 of Regulation S-T during the preceding 12 months (or for such shorter period that the registrant was required to submit such files).",
        "label": "Entity Interactive Data Current",
        "terseLabel": "Entity Interactive Data Current"
       }
      }
     },
     "localname": "EntityInteractiveDataCurrent",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "yesNoItemType"
    },
    "dei_EntityRegistrantName": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The exact name of the entity filing the report as specified in its charter, which is required by forms filed with the SEC.",
        "label": "Entity Registrant Name",
        "terseLabel": "Entity Registrant Name"
       }
      }
     },
     "localname": "EntityRegistrantName",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_EntityShellCompany": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Boolean flag that is true when the registrant is a shell company as defined in Rule 12b-2 of the Exchange Act.",
        "label": "Entity Shell Company",
        "terseLabel": "Entity Shell Company"
       }
      }
     },
     "localname": "EntityShellCompany",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_EntitySmallBusiness": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Indicates that the company is a Smaller Reporting Company (SRC).",
        "label": "Entity Small Business",
        "terseLabel": "Entity Small Business"
       }
      }
     },
     "localname": "EntitySmallBusiness",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_EntityTaxIdentificationNumber": {
     "auth_ref": [
      "r532"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The Tax Identification Number (TIN), also known as an Employer Identification Number (EIN), is a unique 9-digit value assigned by the IRS.",
        "label": "Entity Tax Identification Number",
        "terseLabel": "Entity Tax Identification Number"
       }
      }
     },
     "localname": "EntityTaxIdentificationNumber",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "employerIdItemType"
    },
    "dei_LegalEntityAxis": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The set of legal entities associated with a report.",
        "label": "Legal Entity [Axis]",
        "terseLabel": "Legal Entity [Axis]"
       }
      }
     },
     "localname": "LegalEntityAxis",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "dei_LocalPhoneNumber": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Local phone number for entity.",
        "label": "Local Phone Number",
        "terseLabel": "Local Phone Number"
       }
      }
     },
     "localname": "LocalPhoneNumber",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_Security12bTitle": {
     "auth_ref": [
      "r528"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Title of a 12(b) registered security.",
        "label": "Title of 12(b) Security",
        "terseLabel": "Title of 12(b) Security"
       }
      }
     },
     "localname": "Security12bTitle",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "securityTitleItemType"
    },
    "dei_SecurityExchangeName": {
     "auth_ref": [
      "r529"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Name of the Exchange on which a security is registered.",
        "label": "Security Exchange Name",
        "terseLabel": "Security Exchange Name"
       }
      }
     },
     "localname": "SecurityExchangeName",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "edgarExchangeCodeItemType"
    },
    "dei_TradingSymbol": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Trading symbol of an instrument as listed on an exchange.",
        "label": "Trading Symbol",
        "terseLabel": "Trading Symbol"
       }
      }
     },
     "localname": "TradingSymbol",
     "nsuri": "http://xbrl.sec.gov/dei/2021",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "tradingSymbolItemType"
    },
    "srt_AmericasMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Americas [Member]",
        "terseLabel": "Americas"
       }
      }
     },
     "localname": "AmericasMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_AsiaPacificMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Asia Pacific [Member]",
        "terseLabel": "APAC"
       }
      }
     },
     "localname": "AsiaPacificMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ConsolidationItemsAxis": {
     "auth_ref": [
      "r103",
      "r158",
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r184",
      "r188",
      "r266",
      "r267",
      "r268",
      "r269",
      "r270",
      "r271",
      "r273",
      "r274",
      "r276",
      "r278",
      "r279"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Items [Axis]",
        "terseLabel": "Consolidation Items [Axis]"
       }
      }
     },
     "localname": "ConsolidationItemsAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_ConsolidationItemsDomain": {
     "auth_ref": [
      "r103",
      "r158",
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r184",
      "r188",
      "r266",
      "r267",
      "r268",
      "r269",
      "r270",
      "r271",
      "r273",
      "r274",
      "r276",
      "r278",
      "r279"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Items [Domain]",
        "terseLabel": "Consolidation Items [Domain]"
       }
      }
     },
     "localname": "ConsolidationItemsDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_CounterpartyNameAxis": {
     "auth_ref": [
      "r54",
      "r56",
      "r101",
      "r102",
      "r285",
      "r301"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparty Name [Axis]",
        "terseLabel": "Counterparty Name [Axis]"
       }
      }
     },
     "localname": "CounterpartyNameAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_DirectorMember": {
     "auth_ref": [
      "r197"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Director [Member]",
        "terseLabel": "Director"
       }
      }
     },
     "localname": "DirectorMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_EquityMethodInvesteeNameDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment, Name [Domain]",
        "terseLabel": "Investment, Name [Domain]"
       }
      }
     },
     "localname": "EquityMethodInvesteeNameDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_MajorCustomersAxis": {
     "auth_ref": [
      "r195",
      "r334",
      "r340",
      "r498"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer [Axis]",
        "terseLabel": "Customer [Axis]"
       }
      }
     },
     "localname": "MajorCustomersAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_MaximumMember": {
     "auth_ref": [
      "r284",
      "r300",
      "r357",
      "r359",
      "r450",
      "r451",
      "r452",
      "r453",
      "r454",
      "r455",
      "r456",
      "r495",
      "r499",
      "r525",
      "r526"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maximum [Member]",
        "terseLabel": "Maximum"
       }
      }
     },
     "localname": "MaximumMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_MinimumMember": {
     "auth_ref": [
      "r284",
      "r300",
      "r357",
      "r359",
      "r450",
      "r451",
      "r452",
      "r453",
      "r454",
      "r455",
      "r456",
      "r495",
      "r499",
      "r525",
      "r526"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Minimum [Member]",
        "terseLabel": "Minimum"
       }
      }
     },
     "localname": "MinimumMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_NameOfMajorCustomerDomain": {
     "auth_ref": [
      "r195",
      "r334",
      "r340",
      "r498"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer [Domain]",
        "terseLabel": "Customer [Domain]"
       }
      }
     },
     "localname": "NameOfMajorCustomerDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ProductOrServiceAxis": {
     "auth_ref": [
      "r191",
      "r334",
      "r338",
      "r459",
      "r494",
      "r496"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Product and Service [Axis]",
        "terseLabel": "Product and Service [Axis]"
       }
      }
     },
     "localname": "ProductOrServiceAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_ProductsAndServicesDomain": {
     "auth_ref": [
      "r191",
      "r334",
      "r338",
      "r459",
      "r494",
      "r496"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Product and Service [Domain]",
        "terseLabel": "Product and Service [Domain]"
       }
      }
     },
     "localname": "ProductsAndServicesDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_RangeAxis": {
     "auth_ref": [
      "r284",
      "r300",
      "r347",
      "r357",
      "r359",
      "r450",
      "r451",
      "r452",
      "r453",
      "r454",
      "r455",
      "r456",
      "r495",
      "r499",
      "r525",
      "r526"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statistical Measurement [Axis]",
        "terseLabel": "Statistical Measurement [Axis]"
       }
      }
     },
     "localname": "RangeAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_RangeMember": {
     "auth_ref": [
      "r284",
      "r300",
      "r347",
      "r357",
      "r359",
      "r450",
      "r451",
      "r452",
      "r453",
      "r454",
      "r455",
      "r456",
      "r495",
      "r499",
      "r525",
      "r526"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statistical Measurement [Domain]",
        "terseLabel": "Statistical Measurement [Domain]"
       }
      }
     },
     "localname": "RangeMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_RealEstateAndAccumulatedDepreciationDescriptionOfPropertyAxis": {
     "auth_ref": [
      "r515",
      "r516",
      "r517",
      "r518",
      "r519",
      "r520",
      "r521",
      "r522",
      "r524"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Name of Property [Axis]",
        "terseLabel": "Name of Property [Axis]"
       }
      }
     },
     "localname": "RealEstateAndAccumulatedDepreciationDescriptionOfPropertyAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_RealEstateAndAccumulatedDepreciationNameOfPropertyDomain": {
     "auth_ref": [
      "r515",
      "r516",
      "r517",
      "r518",
      "r519",
      "r520",
      "r521",
      "r522",
      "r524"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Name of Property [Domain]",
        "terseLabel": "Name of Property [Domain]"
       }
      }
     },
     "localname": "RealEstateAndAccumulatedDepreciationNameOfPropertyDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_RepurchaseAgreementCounterpartyNameDomain": {
     "auth_ref": [
      "r55",
      "r56",
      "r101",
      "r102",
      "r285",
      "r301"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparty Name [Domain]",
        "terseLabel": "Counterparty Name [Domain]"
       }
      }
     },
     "localname": "RepurchaseAgreementCounterpartyNameDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScenarioForecastMember": {
     "auth_ref": [
      "r113",
      "r358"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forecast [Member]",
        "terseLabel": "Forecast"
       }
      }
     },
     "localname": "ScenarioForecastMember",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScenarioUnspecifiedDomain": {
     "auth_ref": [
      "r113",
      "r118",
      "r358"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Scenario [Domain]",
        "terseLabel": "Scenario [Domain]"
       }
      }
     },
     "localname": "ScenarioUnspecifiedDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis": {
     "auth_ref": [
      "r216"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment, Name [Axis]",
        "terseLabel": "Investment, Name [Axis]"
       }
      }
     },
     "localname": "ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_SegmentGeographicalDomain": {
     "auth_ref": [
      "r192",
      "r193",
      "r334",
      "r339",
      "r497",
      "r515",
      "r516",
      "r517",
      "r518",
      "r519",
      "r520",
      "r521",
      "r522",
      "r523"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical [Domain]",
        "terseLabel": "Geographical [Domain]"
       }
      }
     },
     "localname": "SegmentGeographicalDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_StatementGeographicalAxis": {
     "auth_ref": [
      "r192",
      "r193",
      "r334",
      "r339",
      "r497",
      "r509",
      "r515",
      "r516",
      "r517",
      "r518",
      "r519",
      "r520",
      "r521",
      "r522",
      "r523"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical [Axis]",
        "terseLabel": "Geographical [Axis]",
        "verboseLabel": "Geographical [Axis]"
       }
      }
     },
     "localname": "StatementGeographicalAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_StatementScenarioAxis": {
     "auth_ref": [
      "r113",
      "r118",
      "r255",
      "r358",
      "r446"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Scenario [Axis]",
        "terseLabel": "Scenario [Axis]"
       }
      }
     },
     "localname": "StatementScenarioAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_TitleOfIndividualAxis": {
     "auth_ref": [
      "r197",
      "r439"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title of Individual [Axis]",
        "terseLabel": "Title of Individual [Axis]"
       }
      }
     },
     "localname": "TitleOfIndividualAxis",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_TitleOfIndividualWithRelationshipToEntityDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title of Individual [Domain]",
        "terseLabel": "Title of Individual [Domain]"
       }
      }
     },
     "localname": "TitleOfIndividualWithRelationshipToEntityDomain",
     "nsuri": "http://fasb.org/srt/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_AccountingPoliciesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accounting Policies [Abstract]",
        "terseLabel": "Accounting Policies [Abstract]"
       }
      }
     },
     "localname": "AccountingPoliciesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_AccountsNotesAndLoansReceivableNetCurrent": {
     "auth_ref": [
      "r5",
      "r21",
      "r47",
      "r198",
      "r199",
      "r478"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, after allowance for credit loss, of accounts and financing receivables, classified as current. Includes, but is not limited to, notes and loan receivable.",
        "label": "Accounts and Financing Receivable, after Allowance for Credit Loss, Current",
        "totalLabel": "Total financial assets, net"
       }
      }
     },
     "localname": "AccountsNotesAndLoansReceivableNetCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsPayableCurrent": {
     "auth_ref": [
      "r37",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_LiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Carrying value as of the balance sheet date of liabilities incurred (and for which invoices have typically been received) and payable to vendors for goods and services received that are used in an entity's business. Used to reflect the current portion of the liabilities (due within one year or within the normal operating cycle if longer).",
        "label": "Accounts Payable, Current",
        "verboseLabel": "Accounts payable"
       }
      }
     },
     "localname": "AccountsPayableCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsReceivableGrossCurrent": {
     "auth_ref": [
      "r198",
      "r199"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_NotesReceivableGross",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, before allowance for credit loss, of right to consideration from customer for product sold and service rendered in normal course of business, classified as current.",
        "label": "Accounts Receivable, before Allowance for Credit Loss, Current",
        "terseLabel": "Accounts receivable"
       }
      }
     },
     "localname": "AccountsReceivableGrossCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsReceivableMember": {
     "auth_ref": [
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Due from customers or clients for goods or services that have been delivered or sold.",
        "label": "Accounts Receivable [Member]",
        "terseLabel": "Accounts Receivable"
       }
      }
     },
     "localname": "AccountsReceivableMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_AccountsReceivableRelatedParties": {
     "auth_ref": [
      "r20",
      "r100",
      "r437",
      "r440",
      "r485"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "For an unclassified balance sheet, amount of receivables arising from transactions with related parties.",
        "label": "Accounts Receivable, Related Parties",
        "terseLabel": "Accounts receivable from related parties"
       }
      }
     },
     "localname": "AccountsReceivableRelatedParties",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccruedLiabilitiesCurrent": {
     "auth_ref": [
      "r40"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_LiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Carrying value as of the balance sheet date of obligations incurred and payable, pertaining to costs that are statutory in nature, are incurred on contractual obligations, or accumulate over time and for which invoices have not yet been received or will not be rendered. Examples include taxes, interest, rent and utilities. Used to reflect the current portion of the liabilities (due within one year or within the normal operating cycle if longer).",
        "label": "Accrued Liabilities, Current",
        "totalLabel": "Total",
        "verboseLabel": "Other accrued liabilities"
       }
      }
     },
     "localname": "AccruedLiabilitiesCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccruedProfessionalFeesCurrentAndNoncurrent": {
     "auth_ref": [
      "r469",
      "r489"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_AccruedLiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Carrying value as of the balance sheet date of obligations incurred through that date and payable for professional fees, such as for legal and accounting services received.",
        "label": "Accrued Professional Fees",
        "terseLabel": "Accrued professional and outside service fees"
       }
      }
     },
     "localname": "AccruedProfessionalFeesCurrentAndNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment": {
     "auth_ref": [
      "r35",
      "r243"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_PropertyPlantAndEquipmentNet",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of accumulated depreciation, depletion and amortization for physical assets used in the normal conduct of business to produce goods and services.",
        "label": "Accumulated Depreciation, Depletion and Amortization, Property, Plant, and Equipment",
        "negatedTerseLabel": "Less: accumulated depreciation and amortization"
       }
      }
     },
     "localname": "AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdditionalPaidInCapital": {
     "auth_ref": [
      "r22",
      "r379",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_StockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of excess of issue price over par or stated value of stock and from other transaction involving stock or stockholder. Includes, but is not limited to, additional paid-in capital (APIC) for common and preferred stock.",
        "label": "Additional Paid in Capital",
        "verboseLabel": "Additional paid-in capital"
       }
      }
     },
     "localname": "AdditionalPaidInCapital",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdditionalPaidInCapitalMember": {
     "auth_ref": [
      "r105",
      "r106",
      "r107",
      "r376",
      "r377",
      "r378",
      "r396"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Excess of issue price over par or stated value of the entity's capital stock and amounts received from other transactions involving the entity's stock or stockholders.",
        "label": "Additional Paid-in Capital [Member]",
        "terseLabel": "Additional paid-in Capital"
       }
      }
     },
     "localname": "AdditionalPaidInCapitalMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_AdjustmentsRelatedToTaxWithholdingForShareBasedCompensation": {
     "auth_ref": [],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of decrease to equity for grantee's tax withholding obligation for award under share-based payment arrangement.",
        "label": "Share-based Payment Arrangement, Decrease for Tax Withholding Obligation",
        "negatedTerseLabel": "Taxes paid related to net shares settlement of equity awards"
       }
      }
     },
     "localname": "AdjustmentsRelatedToTaxWithholdingForShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue": {
     "auth_ref": [
      "r361",
      "r364",
      "r381",
      "r382"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase to additional paid-in capital (APIC) for recognition of cost for award under share-based payment arrangement.",
        "label": "APIC, Share-based Payment Arrangement, Increase for Cost Recognition",
        "verboseLabel": "Employee stock-based compensation"
       }
      }
     },
     "localname": "AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments to Reconcile Net Income (Loss) to Cash Provided by (Used in) Operating Activities [Abstract]",
        "verboseLabel": "Adjustments to reconcile net loss to net cash used in operating activities:"
       }
      }
     },
     "localname": "AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivitiesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock": {
     "auth_ref": [
      "r200",
      "r222"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of allowance for credit loss on financing receivable.",
        "label": "Financing Receivable, Allowance for Credit Loss [Table Text Block]",
        "terseLabel": "Analysis of Allowance for Credit Losses"
       }
      }
     },
     "localname": "AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_AllowanceForNotesAndLoansReceivableCurrent": {
     "auth_ref": [
      "r27",
      "r201",
      "r219"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_AccountsNotesAndLoansReceivableNetCurrent",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of allowance for credit loss on financing receivable, classified as current.",
        "label": "Financing Receivable, Allowance for Credit Loss, Current",
        "negatedLabel": "Less: allowances",
        "terseLabel": "Allowance for credit losses"
       }
      }
     },
     "localname": "AllowanceForNotesAndLoansReceivableCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesAnalysisofAllowanceforCreditLossesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Securities (including those issuable pursuant to contingent stock agreements) that could potentially dilute basic earnings per share (EPS) or earnings per unit (EPU) in the future that were not included in the computation of diluted EPS or EPU because to do so would increase EPS or EPU amounts or decrease loss per share or unit amounts for the period presented.",
        "label": "Antidilutive Securities Excluded from Computation of Earnings Per Share, Amount",
        "terseLabel": "Total shares excluded as anti-dilutive (in shares)"
       }
      }
     },
     "localname": "AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of antidilutive security.",
        "label": "Antidilutive Securities [Axis]",
        "terseLabel": "Antidilutive Securities [Axis]"
       }
      }
     },
     "localname": "AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Antidilutive Securities Excluded from Computation of Earnings Per Share [Line Items]",
        "terseLabel": "Antidilutive Securities Excluded from Computation of Earnings Per Share [Line Items]"
       }
      }
     },
     "localname": "AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AntidilutiveSecuritiesNameDomain": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Incremental common shares attributable to securities that were not included in diluted earnings per share (EPS) because to do so would increase EPS amounts or decrease loss per share amounts for the period presented.",
        "label": "Antidilutive Securities, Name [Domain]",
        "terseLabel": "Antidilutive Securities, Name [Domain]"
       }
      }
     },
     "localname": "AntidilutiveSecuritiesNameDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_AreaOfRealEstateProperty": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Area of a real estate property.",
        "label": "Area of Real Estate Property",
        "terseLabel": "Area of real estate property (in square feet)"
       }
      }
     },
     "localname": "AreaOfRealEstateProperty",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "areaItemType"
    },
    "us-gaap_AssetRetirementObligation": {
     "auth_ref": [
      "r247"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The carrying amount of a liability for an asset retirement obligation. An asset retirement obligation is a legal obligation associated with the disposal or retirement of a tangible long-lived asset that results from the acquisition, construction or development, or the normal operations of a long-lived asset, except for certain obligations of lessees.",
        "label": "Asset Retirement Obligation",
        "verboseLabel": "Asset retirement obligations"
       }
      }
     },
     "localname": "AssetRetirementObligation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AssetUnderConstructionMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Asset in process of being built.",
        "label": "Asset under Construction [Member]",
        "terseLabel": "Asset under Construction"
       }
      }
     },
     "localname": "AssetUnderConstructionMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Assets": {
     "auth_ref": [
      "r98",
      "r166",
      "r179",
      "r186",
      "r217",
      "r266",
      "r267",
      "r268",
      "r270",
      "r271",
      "r272",
      "r273",
      "r275",
      "r277",
      "r279",
      "r280",
      "r391",
      "r393",
      "r407",
      "r443",
      "r445",
      "r464",
      "r479"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sum of the carrying amounts as of the balance sheet date of all assets that are recognized. Assets are probable future economic benefits obtained or controlled by an entity as a result of past transactions or events.",
        "label": "Assets",
        "totalLabel": "Total assets"
       }
      }
     },
     "localname": "Assets",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AssetsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets [Abstract]",
        "verboseLabel": "Assets"
       }
      }
     },
     "localname": "AssetsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AssetsCurrent": {
     "auth_ref": [
      "r6",
      "r7",
      "r53",
      "r98",
      "r217",
      "r266",
      "r267",
      "r268",
      "r270",
      "r271",
      "r272",
      "r273",
      "r275",
      "r277",
      "r279",
      "r280",
      "r391",
      "r393",
      "r407",
      "r443",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sum of the carrying amounts as of the balance sheet date of all assets that are expected to be realized in cash, sold, or consumed within one year (or the normal operating cycle, if longer). Assets are probable future economic benefits obtained or controlled by an entity as a result of past transactions or events.",
        "label": "Assets, Current",
        "totalLabel": "Total current assets"
       }
      }
     },
     "localname": "AssetsCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AssetsCurrentAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets, Current [Abstract]",
        "verboseLabel": "Current assets:"
       }
      }
     },
     "localname": "AssetsCurrentAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AssetsFairValueDisclosure": {
     "auth_ref": [
      "r399"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Fair value portion of probable future economic benefits obtained or controlled by an entity as a result of past transactions or events.",
        "label": "Assets, Fair Value Disclosure",
        "terseLabel": "Total"
       }
      }
     },
     "localname": "AssetsFairValueDisclosure",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis": {
     "auth_ref": [
      "r206",
      "r232"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amortized cost of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale, Amortized Cost",
        "terseLabel": "Non-marketable debt security due in 1 year or less, Adjusted Cost and Carrying Value"
       }
      }
     },
     "localname": "AvailableForSaleDebtSecuritiesAmortizedCostBasis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleDebtSecuritiesGrossUnrealizedGain": {
     "auth_ref": [
      "r208"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 7.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of unrealized gain on investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale, Unrealized Gain",
        "negatedTerseLabel": "Unrealized gain on non-marketable securities"
       }
      }
     },
     "localname": "AvailableForSaleDebtSecuritiesGrossUnrealizedGain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleDebtSecuritiesGrossUnrealizedLoss": {
     "auth_ref": [
      "r209"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of unrealized loss on investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale, Unrealized Loss",
        "terseLabel": "Other-than-temporary impairment losses"
       }
      }
     },
     "localname": "AvailableForSaleDebtSecuritiesGrossUnrealizedLoss",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue": {
     "auth_ref": [
      "r210",
      "r211",
      "r476"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Fair value of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale), with single maturity date and allocated without single maturity date, maturing in next fiscal year following current fiscal year. Excludes interim and annual periods when interim periods are reported from current statement of financial position date (rolling approach).",
        "label": "Debt Securities, Available-for-Sale, Fair Value, Maturity, Allocated and Single Maturity Date, Year One",
        "terseLabel": "Non-marketable debt security due in 1 year or less, Fair Value"
       }
      }
     },
     "localname": "AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleSecuritiesDebtSecurities": {
     "auth_ref": [
      "r205",
      "r207",
      "r232",
      "r468"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale",
        "terseLabel": "Investment in non-marketable debt security",
        "verboseLabel": "Non-marketable debt security"
       }
      }
     },
     "localname": "AvailableForSaleSecuritiesDebtSecurities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AwardTypeAxis": {
     "auth_ref": [
      "r365",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of award under share-based payment arrangement.",
        "label": "Award Type [Axis]",
        "terseLabel": "Award Type [Axis]"
       }
      }
     },
     "localname": "AwardTypeAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_BasisOfAccountingPolicyPolicyTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of accounting policy for basis of accounting, or basis of presentation, used to prepare the financial statements (for example, US Generally Accepted Accounting Principles, Other Comprehensive Basis of Accounting, IFRS).",
        "label": "Basis of Accounting, Policy [Policy Text Block]",
        "verboseLabel": "Basis of Presentation and Principles of Consolidation"
       }
      }
     },
     "localname": "BasisOfAccountingPolicyPolicyTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CapitalExpendituresIncurredButNotYetPaid": {
     "auth_ref": [
      "r91",
      "r92",
      "r93"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Future cash outflow to pay for purchases of fixed assets that have occurred.",
        "label": "Capital Expenditures Incurred but Not yet Paid",
        "terseLabel": "Capital expenditures incurred but not yet paid"
       }
      }
     },
     "localname": "CapitalExpendituresIncurredButNotYetPaid",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CapitalLeaseObligationsIncurred": {
     "auth_ref": [
      "r91",
      "r92"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase in lease obligation from new lease.",
        "label": "Lease Obligation Incurred",
        "terseLabel": "Capital lease obligations incurred"
       }
      }
     },
     "localname": "CapitalLeaseObligationsIncurred",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CapitalizedContractCostNetCurrent": {
     "auth_ref": [
      "r237"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, after accumulated amortization and accumulated impairment loss, of asset recognized from cost incurred to obtain or fulfill contract with customer; classified as current.",
        "label": "Capitalized Contract Cost, Net, Current",
        "terseLabel": "Contract costs"
       }
      }
     },
     "localname": "CapitalizedContractCostNetCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashAndCashEquivalentsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash and Cash Equivalents [Abstract]",
        "terseLabel": "Cash reconciliation:"
       }
      }
     },
     "localname": "CashAndCashEquivalentsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CashAndCashEquivalentsAtCarryingValue": {
     "auth_ref": [
      "r3",
      "r33",
      "r89"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      },
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of currency on hand as well as demand deposits with banks or financial institutions. Includes other kinds of accounts that have the general characteristics of demand deposits. Also includes short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates. Excludes cash and cash equivalents within disposal group and discontinued operation.",
        "label": "Cash and Cash Equivalents, at Carrying Value",
        "terseLabel": "Adjusted Cost",
        "verboseLabel": "Cash and cash equivalents"
       }
      }
     },
     "localname": "CashAndCashEquivalentsAtCarryingValue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashAndCashEquivalentsAxis": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of cash and cash equivalent balance.",
        "label": "Cash and Cash Equivalents [Axis]",
        "terseLabel": "Cash and Cash Equivalents [Axis]"
       }
      }
     },
     "localname": "CashAndCashEquivalentsAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CashAndCashEquivalentsFairValueDisclosure": {
     "auth_ref": [],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Fair value portion of currency on hand as well as demand deposits with banks or financial institutions. Includes other kinds of accounts that have the general characteristics of demand deposits. Also includes short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Cash and Cash Equivalents, Fair Value Disclosure",
        "terseLabel": "Estimated Fair Value",
        "verboseLabel": "Money market funds"
       }
      }
     },
     "localname": "CashAndCashEquivalentsFairValueDisclosure",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashAndCashEquivalentsLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Cash and Cash Equivalents [Line Items]",
        "terseLabel": "Cash and Cash Equivalents [Line Items]"
       }
      }
     },
     "localname": "CashAndCashEquivalentsLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents": {
     "auth_ref": [
      "r80",
      "r89",
      "r94"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash and cash equivalents, and cash and cash equivalents restricted to withdrawal or usage. Excludes amount for disposal group and discontinued operations. Cash includes, but is not limited to, currency on hand, demand deposits with banks or financial institutions, and other accounts with general characteristics of demand deposits. Cash equivalents include, but are not limited to, short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Cash, Cash Equivalents, Restricted Cash and Restricted Cash Equivalents",
        "periodEndLabel": "Cash, cash equivalents and restricted cash at the end of the period",
        "periodStartLabel": "Cash, cash equivalents and restricted cash at the beginning of the period",
        "totalLabel": "Total cash, cash equivalents and restricted cash"
       }
      }
     },
     "localname": "CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect": {
     "auth_ref": [
      "r80",
      "r408"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in cash, cash equivalents, and cash and cash equivalents restricted to withdrawal or usage; including effect from exchange rate change. Cash includes, but is not limited to, currency on hand, demand deposits with banks or financial institutions, and other accounts with general characteristics of demand deposits. Cash equivalents include, but are not limited to, short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Cash, Cash Equivalents, Restricted Cash and Restricted Cash Equivalents, Period Increase (Decrease), Including Exchange Rate Effect",
        "totalLabel": "Net decrease in cash, cash equivalents and restricted cash"
       }
      }
     },
     "localname": "CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashMember": {
     "auth_ref": [
      "r11"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Currency on hand as well as demand deposits with banks or financial institutions. Includes other kinds of accounts that have the general characteristics of demand deposits.",
        "label": "Cash [Member]",
        "terseLabel": "Cash"
       }
      }
     },
     "localname": "CashMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ChangeInContractWithCustomerLiabilityAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Change in Contract with Customer, Liability [Abstract]",
        "terseLabel": "Amounts included in contract liabilities at the beginning of the period:"
       }
      }
     },
     "localname": "ChangeInContractWithCustomerLiabilityAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ClassOfStockDomain": {
     "auth_ref": [
      "r96",
      "r98",
      "r121",
      "r122",
      "r123",
      "r125",
      "r127",
      "r135",
      "r136",
      "r137",
      "r217",
      "r266",
      "r271",
      "r272",
      "r273",
      "r279",
      "r280",
      "r298",
      "r299",
      "r303",
      "r307",
      "r407",
      "r533"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share of stock differentiated by the voting rights the holder receives. Examples include, but are not limited to, common stock, redeemable preferred stock, nonredeemable preferred stock, and convertible stock.",
        "label": "Class of Stock [Domain]",
        "terseLabel": "Class of Stock [Domain]"
       }
      }
     },
     "localname": "ClassOfStockDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CollaborativeArrangementsAndNoncollaborativeArrangementTransactionsLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Collaborative Arrangement and Arrangement Other than Collaborative [Line Items]",
        "terseLabel": "Collaborative Arrangement and Arrangement Other than Collaborative [Line Items]"
       }
      }
     },
     "localname": "CollaborativeArrangementsAndNoncollaborativeArrangementTransactionsLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CommitmentsAndContingencies": {
     "auth_ref": [
      "r44",
      "r254",
      "r470",
      "r488"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Represents the caption on the face of the balance sheet to indicate that the entity has entered into (1) purchase or supply arrangements that will require expending a portion of its resources to meet the terms thereof, and (2) is exposed to potential losses or, less frequently, gains, arising from (a) possible claims against a company's resources due to future performance under contract terms, and (b) possible losses or likely gains from uncertainties that will ultimately be resolved when one or more future events that are deemed likely to occur do occur or fail to occur.",
        "label": "Commitments and Contingencies",
        "verboseLabel": "Commitments and Contingencies (Note 10)"
       }
      }
     },
     "localname": "CommitmentsAndContingencies",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CommitmentsAndContingenciesDisclosureAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commitments and Contingencies Disclosure [Abstract]",
        "terseLabel": "Commitments and Contingencies Disclosure [Abstract]"
       }
      }
     },
     "localname": "CommitmentsAndContingenciesDisclosureAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_CommitmentsAndContingenciesDisclosureTextBlock": {
     "auth_ref": [
      "r251",
      "r252",
      "r253",
      "r261",
      "r514"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for commitments and contingencies.",
        "label": "Commitments and Contingencies Disclosure [Text Block]",
        "terseLabel": "Commitments and Contingencies"
       }
      }
     },
     "localname": "CommitmentsAndContingenciesDisclosureTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingencies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CommonStockCapitalSharesReservedForFutureIssuance": {
     "auth_ref": [
      "r45"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Aggregate number of common shares reserved for future issuance.",
        "label": "Common Stock, Capital Shares Reserved for Future Issuance",
        "terseLabel": "Maximum number of shares to be issued upon exercise of stock options (in shares)"
       }
      }
     },
     "localname": "CommonStockCapitalSharesReservedForFutureIssuance",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockMember": {
     "auth_ref": [
      "r105",
      "r106",
      "r396"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Stock that is subordinate to all other stock of the issuer.",
        "label": "Common Stock [Member]",
        "terseLabel": "Common Stock"
       }
      }
     },
     "localname": "CommonStockMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CommonStockParOrStatedValuePerShare": {
     "auth_ref": [
      "r19"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Face amount or stated value per share of common stock.",
        "label": "Common Stock, Par or Stated Value Per Share",
        "verboseLabel": "Common stock, par value (in usd per share)"
       }
      }
     },
     "localname": "CommonStockParOrStatedValuePerShare",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_CommonStockSharesAuthorized": {
     "auth_ref": [
      "r19"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The maximum number of common shares permitted to be issued by an entity's charter and bylaws.",
        "label": "Common Stock, Shares Authorized",
        "terseLabel": "Common stock, shares authorized (in shares)"
       }
      }
     },
     "localname": "CommonStockSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockSharesIssued": {
     "auth_ref": [
      "r19"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total number of common shares of an entity that have been sold or granted to shareholders (includes common shares that were issued, repurchased and remain in the treasury). These shares represent capital invested by the firm's shareholders and owners, and may be all or only a portion of the number of shares authorized. Shares issued include shares outstanding and shares held in the treasury.",
        "label": "Common Stock, Shares, Issued",
        "terseLabel": "Common stock, shares issued (in shares)"
       }
      }
     },
     "localname": "CommonStockSharesIssued",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockSharesOutstanding": {
     "auth_ref": [
      "r19",
      "r313"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of shares of common stock outstanding. Common stock represent the ownership interest in a corporation.",
        "label": "Common Stock, Shares, Outstanding",
        "terseLabel": "Common stock, shares outstanding (in shares)"
       }
      }
     },
     "localname": "CommonStockSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockValue": {
     "auth_ref": [
      "r19",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_StockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Aggregate par or stated value of issued nonredeemable common stock (or common stock redeemable solely at the option of the issuer). This item includes treasury stock repurchased by the entity. Note: elements for number of nonredeemable common shares, par value and other disclosure concepts are in another section within stockholders' equity.",
        "label": "Common Stock, Value, Issued",
        "verboseLabel": "Common stock, $0.0001 par value per share; 100,000 shares authorized; 64,833 and 64,283 shares issued and outstanding at September\u00a030, 2021 and December\u00a031, 2020, respectively"
       }
      }
     },
     "localname": "CommonStockValue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ComputerEquipmentMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Long lived, depreciable assets that are used in the creation, maintenance and utilization of information systems.",
        "label": "Computer Equipment [Member]",
        "terseLabel": "Computer equipment and software"
       }
      }
     },
     "localname": "ComputerEquipmentMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ConcentrationRiskBenchmarkDomain": {
     "auth_ref": [
      "r146",
      "r147",
      "r195",
      "r404",
      "r405",
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The denominator in a calculation of a disclosed concentration risk percentage.",
        "label": "Concentration Risk Benchmark [Domain]",
        "terseLabel": "Concentration Risk Benchmark [Domain]"
       }
      }
     },
     "localname": "ConcentrationRiskBenchmarkDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ConcentrationRiskByBenchmarkAxis": {
     "auth_ref": [
      "r146",
      "r147",
      "r195",
      "r404",
      "r405",
      "r505",
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by benchmark of concentration risk.",
        "label": "Concentration Risk Benchmark [Axis]",
        "terseLabel": "Concentration Risk Benchmark [Axis]"
       }
      }
     },
     "localname": "ConcentrationRiskByBenchmarkAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskByTypeAxis": {
     "auth_ref": [
      "r146",
      "r147",
      "r195",
      "r404",
      "r405",
      "r505",
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of concentration risk, for example, but not limited to, asset, liability, net assets, geographic, customer, employees, supplier, lender.",
        "label": "Concentration Risk Type [Axis]",
        "terseLabel": "Concentration Risk Type [Axis]"
       }
      }
     },
     "localname": "ConcentrationRiskByTypeAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Concentration Risk [Line Items]",
        "terseLabel": "Concentration Risk [Line Items]"
       }
      }
     },
     "localname": "ConcentrationRiskLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskPercentage1": {
     "auth_ref": [
      "r146",
      "r147",
      "r195",
      "r404",
      "r405"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "For an entity that discloses a concentration risk in relation to quantitative amount, which serves as the \"benchmark\" (or denominator) in the equation, this concept represents the concentration percentage derived from the division.",
        "label": "Concentration Risk, Percentage",
        "terseLabel": "Concentration risk"
       }
      }
     },
     "localname": "ConcentrationRiskPercentage1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_ConcentrationRiskTable": {
     "auth_ref": [
      "r143",
      "r146",
      "r147",
      "r148",
      "r404",
      "r406",
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Describes the nature of a concentration, a benchmark to which it is compared, and the percentage that the risk is to the benchmark.",
        "label": "Concentration Risk [Table]",
        "terseLabel": "Concentration Risk [Table]"
       }
      }
     },
     "localname": "ConcentrationRiskTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskTypeDomain": {
     "auth_ref": [
      "r146",
      "r147",
      "r195",
      "r404",
      "r405",
      "r513"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "For an entity that discloses a concentration risk as a percentage of some financial balance or benchmark, identifies the type (for example, asset, liability, net assets, geographic, customer, employees, supplier, lender) of the concentration.",
        "label": "Concentration Risk Type [Domain]",
        "terseLabel": "Concentration Risk Type [Domain]"
       }
      }
     },
     "localname": "ConcentrationRiskTypeDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ConstructionInProgressMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Structure or a modification to a structure under construction. Includes recently completed structures or modifications to structures that have not been placed into service.",
        "label": "Construction in Progress [Member]",
        "terseLabel": "Construction in progress"
       }
      }
     },
     "localname": "ConstructionInProgressMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ContractWithCustomerAssetAndLiabilityTableTextBlock": {
     "auth_ref": [
      "r322"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of receivable, contract asset, and contract liability from contract with customer. Includes, but is not limited to, change in contract asset and contract liability.",
        "label": "Contract with Customer, Contract Asset, Contract Liability, and Receivable [Table Text Block]",
        "terseLabel": "Contract with Customer"
       }
      }
     },
     "localname": "ContractWithCustomerAssetAndLiabilityTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ContractWithCustomerAssetCreditLossExpense": {
     "auth_ref": [
      "r221",
      "r320",
      "r333"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of expense (reversal of expense) for expected credit loss on right to consideration in exchange for good or service transferred to customer when right is conditioned on something other than passage of time.",
        "label": "Contract with Customer, Asset, Credit Loss Expense (Reversal)",
        "terseLabel": "Impairment charges related to contract assets"
       }
      }
     },
     "localname": "ContractWithCustomerAssetCreditLossExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerAssetGrossCurrent": {
     "auth_ref": [
      "r316",
      "r318"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_NotesReceivableGross",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, before allowance for credit loss, of right to consideration in exchange for good or service transferred to customer when right is conditioned on something other than passage of time, classified as current.",
        "label": "Contract with Customer, Asset, before Allowance for Credit Loss, Current",
        "terseLabel": "Contract assets"
       }
      }
     },
     "localname": "ContractWithCustomerAssetGrossCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiability": {
     "auth_ref": [
      "r316",
      "r317",
      "r335"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of obligation to transfer good or service to customer for which consideration has been received or is receivable.",
        "label": "Contract with Customer, Liability",
        "netLabel": "Deferred revenue",
        "verboseLabel": "Contract liabilities: deferred revenue"
       }
      }
     },
     "localname": "ContractWithCustomerLiability",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized": {
     "auth_ref": [
      "r321"
     ],
     "calculation": {
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of revenue recognized arising from contract liability from change in timeframe for performance obligation to be satisfied.",
        "label": "Contract with Customer, Liability, Change in Timeframe, Performance Obligation Satisfied, Revenue Recognized",
        "totalLabel": "Total revenues"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInEstimateOfTransactionPrice": {
     "auth_ref": [
      "r319"
     ],
     "calculation": {
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in revenue recognized for cumulative catch-up adjustment from change in estimate of transaction price which (increases) decreases obligation to transfer good or service to customer for which consideration from customer has been received or is due. Includes, but is not limited to, change in assessment of whether estimate of variable consideration is constrained.",
        "label": "Contract with Customer, Liability, Cumulative Catch-up Adjustment to Revenue, Change in Estimate of Transaction Price",
        "terseLabel": "Changes in the estimated transaction price allocated to performance obligations satisfied in prior periods"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInEstimateOfTransactionPrice",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityCurrent": {
     "auth_ref": [
      "r316",
      "r317",
      "r335"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 5.0,
       "parentTag": "us-gaap_LiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of obligation to transfer good or service to customer for which consideration has been received or is receivable, classified as current.",
        "label": "Contract with Customer, Liability, Current",
        "terseLabel": "Deferred revenue"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityNoncurrent": {
     "auth_ref": [
      "r316",
      "r317",
      "r335"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_Liabilities",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of obligation to transfer good or service to customer for which consideration has been received or is receivable, classified as noncurrent.",
        "label": "Contract with Customer, Liability, Noncurrent",
        "verboseLabel": "Deferred revenue, net of current portion"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityRevenueRecognized": {
     "auth_ref": [
      "r336"
     ],
     "calculation": {
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of revenue recognized that was previously included in balance of obligation to transfer good or service to customer for which consideration from customer has been received or is due.",
        "label": "Contract with Customer, Liability, Revenue Recognized",
        "verboseLabel": "Performance obligations satisfied"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityRevenueRecognized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ConvertibleDebt": {
     "auth_ref": [
      "r15",
      "r465",
      "r480"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Including the current and noncurrent portions, carrying amount of debt identified as being convertible into another form of financial instrument (typically the entity's common stock) as of the balance sheet date, which originally required full repayment more than twelve months after issuance or greater than the normal operating cycle of the company.",
        "label": "Convertible Debt",
        "terseLabel": "Conversion, debt to equity"
       }
      }
     },
     "localname": "ConvertibleDebt",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ConvertibleDebtMember": {
     "auth_ref": [
      "r281",
      "r282",
      "r283",
      "r284",
      "r286",
      "r287",
      "r288",
      "r289",
      "r290",
      "r291",
      "r292",
      "r293",
      "r294",
      "r295",
      "r296",
      "r297"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Borrowing which can be exchanged for a specified number of another security at the option of the issuer or the holder, for example, but not limited to, the entity's common stock.",
        "label": "Convertible Debt [Member]",
        "terseLabel": "Convertible Debt"
       }
      }
     },
     "localname": "ConvertibleDebtMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CorporateNonSegmentMember": {
     "auth_ref": [
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r188",
      "r190"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Corporate headquarters or functional department that may not earn revenues or may earn revenues that are only incidental to the activities of the entity and is not considered an operating segment.",
        "label": "Corporate, Non-Segment [Member]",
        "terseLabel": "Corporate, non-segment"
       }
      }
     },
     "localname": "CorporateNonSegmentMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CostOfGoodsAndServicesSold": {
     "auth_ref": [
      "r68",
      "r459"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_CostsAndExpenses",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The aggregate costs related to goods produced and sold and services rendered by an entity during the reporting period. This excludes costs incurred during the reporting period related to financial services rendered and other revenue generating activities.",
        "label": "Cost of Goods and Services Sold",
        "terseLabel": "Cost of product revenue"
       }
      }
     },
     "localname": "CostOfGoodsAndServicesSold",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CostsAndExpenses": {
     "auth_ref": [
      "r66"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_OperatingIncomeLoss",
       "weight": -1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total costs of sales and operating expenses for the period.",
        "label": "Costs and Expenses",
        "terseLabel": "Total costs and operating expenses",
        "totalLabel": "Total costs and operating expenses"
       }
      }
     },
     "localname": "CostsAndExpenses",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CreditFacilityAxis": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of credit facility. Credit facilities provide capital to borrowers without the need to structure a loan for each borrowing.",
        "label": "Credit Facility [Axis]",
        "terseLabel": "Credit Facility [Axis]"
       }
      }
     },
     "localname": "CreditFacilityAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CreditFacilityDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Type of credit facility. Credit facilities provide capital to borrowers without the need to structure a loan for each borrowing.",
        "label": "Credit Facility [Domain]",
        "terseLabel": "Credit Facility [Domain]"
       }
      }
     },
     "localname": "CreditFacilityDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CreditLossFinancialInstrumentTextBlock": {
     "auth_ref": [
      "r220",
      "r224",
      "r225",
      "r227",
      "r228",
      "r233",
      "r234"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for credit loss on financial instrument measured at amortized cost basis, net investment in lease, off-balance sheet credit exposure, and available-for-sale debt security.",
        "label": "Credit Loss, Financial Instrument [Text Block]",
        "terseLabel": "Allowance for Credit Losses"
       }
      }
     },
     "localname": "CreditLossFinancialInstrumentTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLosses"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CustomerConcentrationRiskMember": {
     "auth_ref": [
      "r144",
      "r195"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Reflects the percentage that revenues in the period from one or more significant customers is to net revenues, as defined by the entity, such as total net revenues, product line revenues, segment revenues. The risk is the materially adverse effects of loss of a significant customer.",
        "label": "Customer Concentration Risk [Member]",
        "terseLabel": "Customer Concentration Risk"
       }
      }
     },
     "localname": "CustomerConcentrationRiskMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_DebtConversionConvertedInstrumentSharesIssued1": {
     "auth_ref": [
      "r91",
      "r93"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The number of shares issued in exchange for the original debt being converted in a noncash (or part noncash) transaction. \"Part noncash\" refers to that portion of the transaction not resulting in cash receipts or payments in the period.",
        "label": "Debt Conversion, Converted Instrument, Shares Issued",
        "terseLabel": "Debt conversion, shares issued (in shares)"
       }
      }
     },
     "localname": "DebtConversionConvertedInstrumentSharesIssued1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_DebtInstrumentBasisSpreadOnVariableRate1": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Percentage points added to the reference rate to compute the variable rate on the debt instrument.",
        "label": "Debt Instrument, Basis Spread on Variable Rate",
        "terseLabel": "Basis spread on variable rate (percent)"
       }
      }
     },
     "localname": "DebtInstrumentBasisSpreadOnVariableRate1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_DebtInstrumentInterestRateStatedPercentage": {
     "auth_ref": [
      "r42",
      "r283"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Contractual interest rate for funds borrowed, under the debt agreement.",
        "label": "Debt Instrument, Interest Rate, Stated Percentage",
        "terseLabel": "Stated interest rate"
       }
      }
     },
     "localname": "DebtInstrumentInterestRateStatedPercentage",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_DebtSecuritiesAvailableForSaleAllowanceForCreditLossWriteoff": {
     "auth_ref": [
      "r235"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of writeoff of allowance for credit loss on investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale, Allowance for Credit Loss, Writeoff",
        "terseLabel": "Credit losses"
       }
      }
     },
     "localname": "DebtSecuritiesAvailableForSaleAllowanceForCreditLossWriteoff",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_DebtSecuritiesAvailableForSaleTableTextBlock": {
     "auth_ref": [
      "r212"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale).",
        "label": "Debt Securities, Available-for-sale [Table Text Block]",
        "terseLabel": "Details of Non-marketable Debt Securities"
       }
      }
     },
     "localname": "DebtSecuritiesAvailableForSaleTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_DemandDepositsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Accounts that may or may not bear interest and that depositor is entitled to withdraw at anytime without prior notice. Checking and negotiable order of withdrawal (NOW) accounts are the most common forms of demand deposits.",
        "label": "Demand Deposits [Member]",
        "terseLabel": "Demand Deposits"
       }
      }
     },
     "localname": "DemandDepositsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Depreciation": {
     "auth_ref": [
      "r87",
      "r241"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of expense recognized in the current period that reflects the allocation of the cost of tangible assets over the assets' useful lives. Includes production and non-production related depreciation.",
        "label": "Depreciation",
        "negatedTerseLabel": "Unallocated depreciation and amortization",
        "terseLabel": "Depreciation expense",
        "verboseLabel": "Depreciation"
       }
      }
     },
     "localname": "Depreciation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_DisaggregationOfRevenueLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Disaggregation of Revenue [Line Items]",
        "terseLabel": "Disaggregation of Revenue [Line Items]"
       }
      }
     },
     "localname": "DisaggregationOfRevenueLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_DisaggregationOfRevenueTable": {
     "auth_ref": [
      "r334",
      "r338",
      "r339",
      "r340",
      "r341",
      "r342",
      "r343",
      "r344"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about disaggregation of revenue into categories depicting how nature, amount, timing, and uncertainty of revenue and cash flows are affected by economic factor.",
        "label": "Disaggregation of Revenue [Table]",
        "terseLabel": "Disaggregation of Revenue [Table]"
       }
      }
     },
     "localname": "DisaggregationOfRevenueTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_DisaggregationOfRevenueTableTextBlock": {
     "auth_ref": [
      "r334"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of disaggregation of revenue into categories depicting how nature, amount, timing, and uncertainty of revenue and cash flows are affected by economic factor.",
        "label": "Disaggregation of Revenue [Table Text Block]",
        "terseLabel": "Disaggregation of Revenue"
       }
      }
     },
     "localname": "DisaggregationOfRevenueTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock": {
     "auth_ref": [
      "r383"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for share-based payment arrangement.",
        "label": "Share-based Payment Arrangement [Text Block]",
        "terseLabel": "Stock-based Compensation"
       }
      }
     },
     "localname": "DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensation"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_DisclosureOfCompensationRelatedCostsSharebasedPaymentsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share-based Payment Arrangement [Abstract]",
        "terseLabel": "Share-based Payment Arrangement [Abstract]"
       }
      }
     },
     "localname": "DisclosureOfCompensationRelatedCostsSharebasedPaymentsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_EMEAMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Regions of Europe, Middle East and Africa.",
        "label": "EMEA [Member]",
        "terseLabel": "EMEA"
       }
      }
     },
     "localname": "EMEAMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_EarningsPerShareAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings Per Share [Abstract]",
        "terseLabel": "Earnings Per Share [Abstract]"
       }
      }
     },
     "localname": "EarningsPerShareAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_EarningsPerShareBasic": {
     "auth_ref": [
      "r64",
      "r110",
      "r111",
      "r112",
      "r113",
      "r114",
      "r119",
      "r121",
      "r125",
      "r126",
      "r127",
      "r131",
      "r132",
      "r397",
      "r398",
      "r473",
      "r491"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of net income (loss) for the period per each share of common stock or unit outstanding during the reporting period.",
        "label": "Earnings Per Share, Basic",
        "terseLabel": "Net income (loss) per share, basic (in usd per share)"
       }
      }
     },
     "localname": "EarningsPerShareBasic",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_EarningsPerShareDiluted": {
     "auth_ref": [
      "r64",
      "r110",
      "r111",
      "r112",
      "r113",
      "r114",
      "r121",
      "r125",
      "r126",
      "r127",
      "r131",
      "r132",
      "r397",
      "r398",
      "r473",
      "r491"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of net income (loss) for the period available to each share of common stock or common unit outstanding during the reporting period and to each share or unit that would have been outstanding assuming the issuance of common shares or units for all dilutive potential common shares or units outstanding during the reporting period.",
        "label": "Earnings Per Share, Diluted",
        "terseLabel": "Net income (loss) per share, diluted (in usd per share)"
       }
      }
     },
     "localname": "EarningsPerShareDiluted",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_EarningsPerShareTextBlock": {
     "auth_ref": [
      "r128",
      "r129",
      "r130",
      "r133"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for earnings per share.",
        "label": "Earnings Per Share [Text Block]",
        "terseLabel": "Net Income (loss) per Share"
       }
      }
     },
     "localname": "EarningsPerShareTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShare"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_EmbeddedDerivativeGainOnEmbeddedDerivative": {
     "auth_ref": [
      "r395"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Increase in the fair value of the embedded derivative or group of embedded derivatives included in earnings in the period.",
        "label": "Embedded Derivative, Gain on Embedded Derivative",
        "terseLabel": "Change in fair value of embedded bifurcated derivative recognized in other income"
       }
      }
     },
     "localname": "EmbeddedDerivativeGainOnEmbeddedDerivative",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmbeddedDerivativeLossOnEmbeddedDerivative": {
     "auth_ref": [
      "r395"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Decrease in the fair value of the embedded derivative or group of embedded derivatives included in earnings in the period.",
        "label": "Embedded Derivative, Loss on Embedded Derivative",
        "terseLabel": "Change in fair value of embedded bifurcated derivative recognized in other expense"
       }
      }
     },
     "localname": "EmbeddedDerivativeLossOnEmbeddedDerivative",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeRelatedLiabilitiesCurrent": {
     "auth_ref": [
      "r40"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_LiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total of the carrying values as of the balance sheet date of obligations incurred through that date and payable for obligations related to services received from employees, such as accrued salaries and bonuses, payroll taxes and fringe benefits. Used to reflect the current portion of the liabilities (due within one year or within the normal operating cycle if longer).",
        "label": "Employee-related Liabilities, Current",
        "verboseLabel": "Accrued compensation"
       }
      }
     },
     "localname": "EmployeeRelatedLiabilitiesCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Share-based Payment Arrangement, Expensed and Capitalized, Amount [Line Items]",
        "terseLabel": "Share-based Payment Arrangement, Expensed and Capitalized, Amount [Line Items]"
       }
      }
     },
     "localname": "EmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedShareBasedAwardsOtherThanOptions": {
     "auth_ref": [
      "r373"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cost to be recognized for nonvested award under share-based payment arrangement. Excludes share and unit options.",
        "label": "Share-based Payment Arrangement, Nonvested Award, Excluding Option, Cost Not yet Recognized, Amount",
        "terseLabel": "Compensation not yet recognized, share-based awards other than options"
       }
      }
     },
     "localname": "EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedShareBasedAwardsOtherThanOptions",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions": {
     "auth_ref": [
      "r373"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cost to be recognized for option under share-based payment arrangement.",
        "label": "Share-based Payment Arrangement, Nonvested Award, Option, Cost Not yet Recognized, Amount",
        "terseLabel": "Compensation not yet recognized, stock options"
       }
      }
     },
     "localname": "EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeStockOptionMember": {
     "auth_ref": [
      "r371"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based payment arrangement granting right, subject to vesting and other restrictions, to purchase or sell certain number of shares at predetermined price for specified period of time.",
        "label": "Share-based Payment Arrangement, Option [Member]",
        "terseLabel": "Stock Options",
        "verboseLabel": "Stock options"
       }
      }
     },
     "localname": "EmployeeStockOptionMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_EquityAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity [Abstract]",
        "terseLabel": "Equity [Abstract]"
       }
      }
     },
     "localname": "EquityAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_EquityComponentDomain": {
     "auth_ref": [
      "r0",
      "r59",
      "r60",
      "r61",
      "r105",
      "r106",
      "r107",
      "r109",
      "r115",
      "r117",
      "r134",
      "r218",
      "r313",
      "r314",
      "r376",
      "r377",
      "r378",
      "r386",
      "r387",
      "r396",
      "r409",
      "r410",
      "r411",
      "r412",
      "r413",
      "r414",
      "r500",
      "r501",
      "r502",
      "r556"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Components of equity are the parts of the total Equity balance including that which is allocated to common, preferred, treasury stock, retained earnings, etc.",
        "label": "Equity Component [Domain]",
        "terseLabel": "Equity Component [Domain]"
       }
      }
     },
     "localname": "EquityComponentDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueAmount": {
     "auth_ref": [
      "r213"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of investment in equity security without readily determinable fair value.",
        "label": "Equity Securities without Readily Determinable Fair Value, Amount",
        "terseLabel": "Investment in non-marketable equity securities"
       }
      }
     },
     "localname": "EquitySecuritiesWithoutReadilyDeterminableFairValueAmount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueDownwardPriceAdjustmentAnnualAmount": {
     "auth_ref": [
      "r214"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of loss from downward price adjustment on investment in equity security without readily determinable fair value.",
        "label": "Equity Securities without Readily Determinable Fair Value, Downward Price Adjustment, Annual Amount",
        "terseLabel": "Downward price adjustment, annual amount"
       }
      }
     },
     "localname": "EquitySecuritiesWithoutReadilyDeterminableFairValueDownwardPriceAdjustmentAnnualAmount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueTableTextBlock": {
     "auth_ref": [
      "r213",
      "r214",
      "r215"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of investment in equity security without readily determinable fair value.",
        "label": "Equity Securities without Readily Determinable Fair Value [Table Text Block]",
        "terseLabel": "Carrying Value of Non-marketable Equity Securities"
       }
      }
     },
     "localname": "EquitySecuritiesWithoutReadilyDeterminableFairValueTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueUpwardPriceAdjustmentAnnualAmount": {
     "auth_ref": [
      "r215"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of gain from upward price adjustment on investment in equity security without readily determinable fair value.",
        "label": "Equity Securities without Readily Determinable Fair Value, Upward Price Adjustment, Annual Amount",
        "terseLabel": "Upward price adjustment, annual amount"
       }
      }
     },
     "localname": "EquitySecuritiesWithoutReadilyDeterminableFairValueUpwardPriceAdjustmentAnnualAmount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items]",
        "terseLabel": "Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items]"
       }
      }
     },
     "localname": "FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable": {
     "auth_ref": [
      "r399",
      "r400",
      "r401",
      "r402"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about asset and liability measured at fair value on recurring and nonrecurring basis.",
        "label": "Fair Value, Recurring and Nonrecurring [Table]",
        "terseLabel": "Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Table]"
       }
      }
     },
     "localname": "FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueAssetsMeasuredOnRecurringBasisTextBlock": {
     "auth_ref": [
      "r399",
      "r400"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of assets, including [financial] instruments measured at fair value that are classified in stockholders' equity, if any, by class that are measured at fair value on a recurring basis. The disclosures contemplated herein include the fair value measurements at the reporting date by the level within the fair value hierarchy in which the fair value measurements in their entirety fall, segregating fair value measurements using quoted prices in active markets for identical assets (Level 1), significant other observable inputs (Level 2), and significant unobservable inputs (Level 3).",
        "label": "Fair Value, Assets Measured on Recurring Basis [Table Text Block]",
        "verboseLabel": "Summary of Financial Instruments Measured at Fair Value on a Recurring Basis"
       }
      }
     },
     "localname": "FairValueAssetsMeasuredOnRecurringBasisTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_FairValueByFairValueHierarchyLevelAxis": {
     "auth_ref": [
      "r288",
      "r294",
      "r295",
      "r348",
      "r349",
      "r350",
      "r351",
      "r352",
      "r353",
      "r354",
      "r356",
      "r400",
      "r447",
      "r448",
      "r449"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by level within fair value hierarchy and fair value measured at net asset value per share as practical expedient.",
        "label": "Fair Value Hierarchy and NAV [Axis]",
        "terseLabel": "Fair Value Hierarchy and NAV [Axis]"
       }
      }
     },
     "localname": "FairValueByFairValueHierarchyLevelAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueDisclosuresAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Disclosures [Abstract]",
        "terseLabel": "Fair Value Disclosures [Abstract]"
       }
      }
     },
     "localname": "FairValueDisclosuresAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueInputsLevel1Member": {
     "auth_ref": [
      "r288",
      "r348",
      "r349",
      "r354",
      "r356",
      "r400",
      "r447"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Quoted prices in active markets for identical assets or liabilities that the reporting entity can access at the measurement date.",
        "label": "Fair Value, Inputs, Level 1 [Member]",
        "terseLabel": "Level 1"
       }
      }
     },
     "localname": "FairValueInputsLevel1Member",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FairValueInputsLevel3Member": {
     "auth_ref": [
      "r288",
      "r294",
      "r295",
      "r348",
      "r349",
      "r350",
      "r351",
      "r352",
      "r353",
      "r354",
      "r356",
      "r400",
      "r449"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Unobservable inputs that reflect the entity's own assumption about the assumptions market participants would use in pricing.",
        "label": "Fair Value, Inputs, Level 3 [Member]",
        "terseLabel": "Level\u00a03"
       }
      }
     },
     "localname": "FairValueInputsLevel3Member",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FairValueMeasurementInputsDisclosureTextBlock": {
     "auth_ref": [
      "r403"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure of the fair value measurement of assets and liabilities, which includes financial instruments measured at fair value that are classified in shareholders' equity, which may be measured on a recurring or nonrecurring basis.",
        "label": "Fair Value Measurement and Measurement Inputs, Recurring and Nonrecurring [Text Block]",
        "verboseLabel": "Fair Value Measurements"
       }
      }
     },
     "localname": "FairValueMeasurementInputsDisclosureTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurements"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_FairValueMeasurementsFairValueHierarchyDomain": {
     "auth_ref": [
      "r288",
      "r294",
      "r295",
      "r348",
      "r349",
      "r350",
      "r351",
      "r352",
      "r353",
      "r354",
      "r356",
      "r447",
      "r448",
      "r449"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Categories used to prioritize the inputs to valuation techniques to measure fair value.",
        "label": "Fair Value Hierarchy and NAV [Domain]",
        "terseLabel": "Fair Value, Measurements, Fair Value Hierarchy [Domain]"
       }
      }
     },
     "localname": "FairValueMeasurementsFairValueHierarchyDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinanceLeaseInterestExpense": {
     "auth_ref": [
      "r417",
      "r422",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 2.0,
       "parentTag": "cdxs_FinanceLeaseCost",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of interest expense on finance lease liability.",
        "label": "Finance Lease, Interest Expense",
        "terseLabel": "Interest on lease obligations"
       }
      }
     },
     "localname": "FinanceLeaseInterestExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinanceLeasePrincipalPayments": {
     "auth_ref": [
      "r418",
      "r427"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInFinancingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash outflow for principal payment on finance lease.",
        "label": "Finance Lease, Principal Payments",
        "negatedLabel": "Payments of lease obligations - Finance leases",
        "terseLabel": "Financing cash flows from finance leases"
       }
      }
     },
     "localname": "FinanceLeasePrincipalPayments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesCashPaidforLeaseObligationsDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinanceLeaseRightOfUseAsset": {
     "auth_ref": [
      "r415"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 5.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, after accumulated amortization, of right-of-use asset from finance lease.",
        "label": "Finance Lease, Right-of-Use Asset, after Accumulated Amortization",
        "terseLabel": "Right-of-use assets - Finance leases, net"
       }
      }
     },
     "localname": "FinanceLeaseRightOfUseAsset",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinanceLeaseRightOfUseAssetAmortization": {
     "auth_ref": [
      "r417",
      "r422",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 1.0,
       "parentTag": "cdxs_FinanceLeaseCost",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of amortization expense attributable to right-of-use asset from finance lease.",
        "label": "Finance Lease, Right-of-Use Asset, Amortization",
        "terseLabel": "Amortization of right-of-use assets"
       }
      }
     },
     "localname": "FinanceLeaseRightOfUseAssetAmortization",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinancialAssetNotPastDueMember": {
     "auth_ref": [
      "r223",
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Financial asset not past due.",
        "label": "Financial Asset, Not Past Due [Member]",
        "terseLabel": "Current"
       }
      }
     },
     "localname": "FinancialAssetNotPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancialInstrumentsFinancialAssetsBalanceSheetGroupingsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments, Financial Assets, Balance Sheet Groupings [Abstract]",
        "verboseLabel": "Summary of financial instruments measured at fair value on a recurring basis"
       }
      }
     },
     "localname": "FinancialInstrumentsFinancialAssetsBalanceSheetGroupingsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivableAllowanceForCreditLossesLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Financing Receivable, Allowance for Credit Loss [Line Items]",
        "terseLabel": "Financing Receivable, Allowance for Credit Loss [Line Items]"
       }
      }
     },
     "localname": "FinancingReceivableAllowanceForCreditLossesLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivableBeforeAllowanceForCreditLossAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financing Receivable, before Allowance for Credit Loss [Abstract]",
        "terseLabel": "Financial assets:"
       }
      }
     },
     "localname": "FinancingReceivableBeforeAllowanceForCreditLossAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivables30To59DaysPastDueMember": {
     "auth_ref": [
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Financial asset more than 29 days past due but fewer than 60 days past due.",
        "label": "Financial Asset, 30 to 59 Days Past Due [Member]",
        "terseLabel": "31-60 Days"
       }
      }
     },
     "localname": "FinancingReceivables30To59DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivables60To89DaysPastDueMember": {
     "auth_ref": [
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Financial asset more than 59 days past due but fewer than 90 days past due.",
        "label": "Financial Asset, 60 to 89 Days Past Due [Member]",
        "terseLabel": "61-90 Days"
       }
      }
     },
     "localname": "FinancingReceivables60To89DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivablesEqualToGreaterThan90DaysPastDueMember": {
     "auth_ref": [
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Financial asset equal to or greater than 90 days past due.",
        "label": "Financial Asset, Equal to or Greater than 90 Days Past Due [Member]",
        "terseLabel": "91 Days and over"
       }
      }
     },
     "localname": "FinancingReceivablesEqualToGreaterThan90DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivablesPeriodPastDueAxis": {
     "auth_ref": [
      "r203",
      "r223",
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by period in which financial asset is past due or not past due.",
        "label": "Financial Asset, Aging [Axis]",
        "terseLabel": "Financial Asset, Aging [Axis]"
       }
      }
     },
     "localname": "FinancingReceivablesPeriodPastDueAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivablesPeriodPastDueDomain": {
     "auth_ref": [
      "r203",
      "r223",
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Period in which financial asset is past due or not past due. For past due, element name and standard label in Financial Asset, [numeric lower end] to [numeric higher end] [date measure] Past Due [Member] or Financial Asset, Greater than [low end numeric value] [date measure] Past Due [Member] or Financial Asset, Less than [high end numeric value] [date measure] Past Due [Member] formats.",
        "label": "Financial Asset, Aging [Domain]",
        "terseLabel": "Financial Asset, Aging [Domain]"
       }
      }
     },
     "localname": "FinancingReceivablesPeriodPastDueDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_GeographicAreasLongLivedAssetsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographic Areas, Long-Lived Assets [Abstract]",
        "terseLabel": "Geographic Areas, Long-Lived Assets [Abstract]"
       }
      }
     },
     "localname": "GeographicAreasLongLivedAssetsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_GeographicDistributionAxis": {
     "auth_ref": [
      "r229",
      "r474",
      "r475",
      "r533",
      "r534",
      "r535",
      "r536",
      "r537",
      "r538",
      "r539",
      "r540",
      "r541",
      "r542",
      "r543",
      "r544",
      "r549",
      "r550",
      "r551",
      "r552",
      "r553",
      "r554"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by geographic distribution of business activity identified as either domestic or foreign. Excludes names of countries, states and provinces, and cities.",
        "label": "Geographic Distribution [Axis]",
        "terseLabel": "Geographic Distribution [Axis]"
       }
      }
     },
     "localname": "GeographicDistributionAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_GeographicDistributionDomain": {
     "auth_ref": [
      "r474",
      "r475",
      "r533",
      "r534",
      "r535",
      "r536",
      "r537",
      "r538",
      "r539",
      "r540",
      "r541",
      "r542",
      "r543",
      "r544",
      "r549",
      "r550",
      "r551",
      "r552",
      "r553",
      "r554"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Allocation of business activity identified as domestic or foreign. Excludes names of countries, states and provinces, and cities.",
        "label": "Geographic Distribution [Domain]",
        "terseLabel": "Geographic Distribution [Domain]"
       }
      }
     },
     "localname": "GeographicDistributionDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Goodwill": {
     "auth_ref": [
      "r238",
      "r239",
      "r445",
      "r463"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 7.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount after accumulated impairment loss of an asset representing future economic benefits arising from other assets acquired in a business combination that are not individually identified and separately recognized.",
        "label": "Goodwill",
        "terseLabel": "Goodwill",
        "verboseLabel": "Goodwill"
       }
      }
     },
     "localname": "Goodwill",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsGoodwillDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_GranteeStatusAxis": {
     "auth_ref": [
      "r360",
      "r362",
      "r371"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by status of recipient to whom award is granted.",
        "label": "Grantee Status [Axis]",
        "terseLabel": "Grantee Status [Axis]"
       }
      }
     },
     "localname": "GranteeStatusAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_GranteeStatusDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Status of recipient to whom award is granted.",
        "label": "Grantee Status [Domain]",
        "terseLabel": "Grantee Status [Domain]"
       }
      }
     },
     "localname": "GranteeStatusDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest": {
     "auth_ref": [
      "r62",
      "r166",
      "r178",
      "r182",
      "r185",
      "r188",
      "r460",
      "r471",
      "r475",
      "r492"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_NetIncomeLoss",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of income (loss) from continuing operations, including income (loss) from equity method investments, before deduction of income tax expense (benefit), and income (loss) attributable to noncontrolling interest.",
        "label": "Income (Loss) from Continuing Operations before Income Taxes, Noncontrolling Interest",
        "totalLabel": "Income (loss) before income taxes"
       }
      }
     },
     "localname": "IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments": {
     "auth_ref": [
      "r166",
      "r178",
      "r182",
      "r185",
      "r188"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of income (loss) from continuing operations before deduction of income tax expense (benefit) and income (loss) attributable to noncontrolling interest, and addition of income (loss) from equity method investments.",
        "label": "Income (Loss) from Continuing Operations before Equity Method Investments, Income Taxes, Noncontrolling Interest",
        "verboseLabel": "Income (loss) before income taxes"
       }
      }
     },
     "localname": "IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncomeStatementAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Statement [Abstract]",
        "terseLabel": "Income Statement [Abstract]"
       }
      }
     },
     "localname": "IncomeStatementAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncomeStatementLocationAxis": {
     "auth_ref": [
      "r245",
      "r248"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by location in the income statement.",
        "label": "Income Statement Location [Axis]",
        "terseLabel": "Income Statement Location [Axis]"
       }
      }
     },
     "localname": "IncomeStatementLocationAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncomeStatementLocationDomain": {
     "auth_ref": [
      "r248"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Location in the income statement.",
        "label": "Income Statement Location [Domain]",
        "terseLabel": "Income Statement Location [Domain]"
       }
      }
     },
     "localname": "IncomeStatementLocationDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_IncomeTaxExpenseBenefit": {
     "auth_ref": [
      "r99",
      "r116",
      "r117",
      "r164",
      "r385",
      "r388",
      "r389",
      "r493"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_NetIncomeLoss",
       "weight": -1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of current income tax expense (benefit) and deferred income tax expense (benefit) pertaining to continuing operations.",
        "label": "Income Tax Expense (Benefit)",
        "verboseLabel": "Provision for income taxes"
       }
      }
     },
     "localname": "IncomeTaxExpenseBenefit",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncomeTaxesPaid": {
     "auth_ref": [
      "r83",
      "r90"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of cash paid during the current period to foreign, federal, state, and local authorities as taxes on income.",
        "label": "Income Taxes Paid",
        "terseLabel": "Income taxes paid"
       }
      }
     },
     "localname": "IncomeTaxesPaid",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInAccountsPayable": {
     "auth_ref": [
      "r86"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 12.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The increase (decrease) during the reporting period in the aggregate amount of liabilities incurred (and for which invoices have typically been received) and payable to vendors for goods and services received that are used in an entity's business.",
        "label": "Increase (Decrease) in Accounts Payable",
        "verboseLabel": "Accounts payable"
       }
      }
     },
     "localname": "IncreaseDecreaseInAccountsPayable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInContractWithCustomerLiability": {
     "auth_ref": [
      "r86",
      "r457"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 15.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in obligation to transfer good or service to customer for which consideration has been received or is receivable.",
        "label": "Increase (Decrease) in Contract with Customer, Liability",
        "verboseLabel": "Deferred revenue"
       }
      }
     },
     "localname": "IncreaseDecreaseInContractWithCustomerLiability",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInFinanceReceivables": {
     "auth_ref": [
      "r86"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 9.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The increase (decrease) during the reporting period in outstanding loans including accrued interest.",
        "label": "Increase (Decrease) in Finance Receivables",
        "negatedLabel": "Financial assets, net"
       }
      }
     },
     "localname": "IncreaseDecreaseInFinanceReceivables",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInInventories": {
     "auth_ref": [
      "r86"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 10.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The increase (decrease) during the reporting period in the aggregate value of all inventory held by the reporting entity, associated with underlying transactions that are classified as operating activities.",
        "label": "Increase (Decrease) in Inventories",
        "negatedLabel": "Inventories"
       }
      }
     },
     "localname": "IncreaseDecreaseInInventories",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInOperatingCapitalAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase (Decrease) in Operating Capital [Abstract]",
        "verboseLabel": "Changes in operating assets and liabilities:"
       }
      }
     },
     "localname": "IncreaseDecreaseInOperatingCapitalAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncreaseDecreaseInOtherNoncurrentLiabilities": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 14.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in noncurrent operating liabilities classified as other.",
        "label": "Increase (Decrease) in Other Noncurrent Liabilities",
        "terseLabel": "Other long-term liabilities"
       }
      }
     },
     "localname": "IncreaseDecreaseInOtherNoncurrentLiabilities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets": {
     "auth_ref": [
      "r86"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 11.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in prepaid expenses, and assets classified as other.",
        "label": "Increase (Decrease) in Prepaid Expense and Other Assets",
        "negatedLabel": "Prepaid expenses and other assets"
       }
      }
     },
     "localname": "IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInStockholdersEquityRollForward": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "A roll forward is a reconciliation of a concept from the beginning of a period to the end of a period.",
        "label": "Increase (Decrease) in Stockholders' Equity [Roll Forward]",
        "terseLabel": "Increase (Decrease) in Stockholders' Equity [Roll Forward]"
       }
      }
     },
     "localname": "IncreaseDecreaseInStockholdersEquityRollForward",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IndemnificationGuaranteeMember": {
     "auth_ref": [
      "r262",
      "r265"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "An agreement (contract) that contingently requires the guarantor to make payments to the guaranteed party in compensation for that party's or parties' loss or injury attributable to specified events or actions, such as a patent infringement action against an entity that relied on certain representations as to ownership rights made by a software vendor.",
        "label": "Indemnification Agreement [Member]",
        "terseLabel": "Indemnification Agreement"
       }
      }
     },
     "localname": "IndemnificationGuaranteeMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_InterestPaidNet": {
     "auth_ref": [
      "r79",
      "r82",
      "r90"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash paid for interest, excluding capitalized interest, classified as operating activity. Includes, but is not limited to, payment to settle zero-coupon bond for accreted interest of debt discount and debt instrument with insignificant coupon interest rate in relation to effective interest rate of borrowing attributable to accreted interest of debt discount.",
        "label": "Interest Paid, Excluding Capitalized Interest, Operating Activities",
        "terseLabel": "Interest paid"
       }
      }
     },
     "localname": "InterestPaidNet",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryFinishedGoods": {
     "auth_ref": [
      "r48"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails": {
       "order": 3.0,
       "parentTag": "us-gaap_InventoryNet",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before valuation and LIFO reserves of completed merchandise or goods expected to be sold within one year or operating cycle, if longer.",
        "label": "Inventory, Finished Goods, Gross",
        "terseLabel": "Finished goods"
       }
      }
     },
     "localname": "InventoryFinishedGoods",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryNet": {
     "auth_ref": [
      "r4",
      "r51",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 5.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount after valuation and LIFO reserves of inventory expected to be sold, or consumed within one year or operating cycle, if longer.",
        "label": "Inventory, Net",
        "totalLabel": "Inventories",
        "verboseLabel": "Inventories"
       }
      }
     },
     "localname": "InventoryNet",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryNetAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inventory, Net [Abstract]",
        "verboseLabel": "Schedule of Inventory Components"
       }
      }
     },
     "localname": "InventoryNetAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_InventoryRawMaterials": {
     "auth_ref": [
      "r50"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_InventoryNet",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before valuation and LIFO reserves of raw materials expected to be sold, or consumed within one year or operating cycle, if longer.",
        "label": "Inventory, Raw Materials, Gross",
        "terseLabel": "Raw materials"
       }
      }
     },
     "localname": "InventoryRawMaterials",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryValuationReserves": {
     "auth_ref": [
      "r51",
      "r236"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of valuation reserve for inventory.",
        "label": "Inventory Valuation Reserves",
        "terseLabel": "Inventory reserves"
       }
      }
     },
     "localname": "InventoryValuationReserves",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryWorkInProcess": {
     "auth_ref": [
      "r49"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_InventoryNet",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before valuation and LIFO reserves of merchandise or goods in the production process expected to be completed within one year or operating cycle, if longer.",
        "label": "Inventory, Work in Process, Gross",
        "terseLabel": "Work-in-process"
       }
      }
     },
     "localname": "InventoryWorkInProcess",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeAmortizationOfDiscount": {
     "auth_ref": [
      "r71"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of accretion of purchase discount on nonoperating securities.",
        "label": "Investment Income, Amortization of Discount",
        "terseLabel": "Interest income from amortization of discount"
       }
      }
     },
     "localname": "InvestmentIncomeAmortizationOfDiscount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeAmortizationOfPremium": {
     "auth_ref": [
      "r71"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of amortization of purchase premium on nonoperating securities.",
        "label": "Investment Income, Amortization of Premium",
        "terseLabel": "Other expenses"
       }
      }
     },
     "localname": "InvestmentIncomeAmortizationOfPremium",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeInterest": {
     "auth_ref": [
      "r70",
      "r159"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before accretion (amortization) of purchase discount (premium) of interest income on nonoperating securities.",
        "label": "Investment Income, Interest",
        "verboseLabel": "Interest income"
       }
      }
     },
     "localname": "InvestmentIncomeInterest",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentOwnedBalanceShares": {
     "auth_ref": [
      "r506",
      "r508"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Balance held at close of period in number of shares.",
        "label": "Investment Owned, Balance, Shares",
        "terseLabel": "Number of shares purchased (in shares)"
       }
      }
     },
     "localname": "InvestmentOwnedBalanceShares",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_InvestmentsAndOtherNoncurrentAssets": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of investments, and noncurrent assets classified as other.",
        "label": "Investments and Other Noncurrent Assets",
        "terseLabel": "Investment at cost basis",
        "verboseLabel": "Investment in non-marketable equity securities"
       }
      }
     },
     "localname": "InvestmentsAndOtherNoncurrentAssets",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentsDebtAndEquitySecuritiesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investments, Debt and Equity Securities [Abstract]"
       }
      }
     },
     "localname": "InvestmentsDebtAndEquitySecuritiesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_InvestmentsInDebtAndEquityInstrumentsCashAndCashEquivalentsUnrealizedAndRealizedGainsLossesTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for cash, cash equivalents, investments in debt and equity instruments (including cost and equity investees and related income statement amounts), equity and cost method investments, investments in joint ventures and any other investment.",
        "label": "Investments in Debt and Equity Instruments, Cash and Cash Equivalents, Unrealized and Realized Gains (Losses) [Text Block]",
        "terseLabel": "Investments in Non-Marketable Securities"
       }
      }
     },
     "localname": "InvestmentsInDebtAndEquityInstrumentsCashAndCashEquivalentsUnrealizedAndRealizedGainsLossesTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecurities"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LeaseCost": {
     "auth_ref": [
      "r430",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lease cost recognized by lessee for lease contract.",
        "label": "Lease, Cost",
        "totalLabel": "Total lease cost"
       }
      }
     },
     "localname": "LeaseCost",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LeaseCostAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Lease, Cost [Abstract]",
        "terseLabel": "Lease, Cost [Abstract]"
       }
      }
     },
     "localname": "LeaseCostAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LeaseCostTableTextBlock": {
     "auth_ref": [
      "r430"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of lessee's lease cost. Includes, but is not limited to, interest expense for finance lease, amortization of right-of-use asset for finance lease, operating lease cost, short-term lease cost, variable lease cost and sublease income.",
        "label": "Lease, Cost [Table Text Block]",
        "terseLabel": "Lease Cost"
       }
      }
     },
     "localname": "LeaseCostTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LeaseholdImprovementsGross": {
     "auth_ref": [
      "r9",
      "r242"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before accumulated depreciation of additions or improvements to assets held under a lease arrangement.",
        "label": "Leasehold Improvements, Gross",
        "terseLabel": "Tenant improvement allowance"
       }
      }
     },
     "localname": "LeaseholdImprovementsGross",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LeaseholdImprovementsMember": {
     "auth_ref": [
      "r242"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Additions or improvements to assets held under a lease arrangement.",
        "label": "Leasehold Improvements [Member]",
        "terseLabel": "Leasehold improvements"
       }
      }
     },
     "localname": "LeaseholdImprovementsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_LeaseholdsAndLeaseholdImprovementsMember": {
     "auth_ref": [
      "r242"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Assets held by a lessee under a capital lease and any addition or improvement to assets held under a lease arrangement (including addition or improvement to assets held by lessee under an operating lease arrangement).",
        "label": "Leaseholds and Leasehold Improvements [Member]",
        "terseLabel": "Leaseholds and Leasehold Improvements"
       }
      }
     },
     "localname": "LeaseholdsAndLeaseholdImprovementsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_LesseeFinanceLeaseTermOfContract1": {
     "auth_ref": [
      "r420"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Term of lessee's finance lease, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Lessee, Finance Lease, Term of Contract",
        "terseLabel": "Term of contract"
       }
      }
     },
     "localname": "LesseeFinanceLeaseTermOfContract1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedDiscountRate": {
     "auth_ref": [
      "r421"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Discount rate used by lessee to determine present value of operating lease payments for lease that has not yet commenced.",
        "label": "Lessee, Operating Lease, Lease Not yet Commenced, Discount Rate",
        "terseLabel": "Annual rent increases (as a percent)"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLeaseNotYetCommencedDiscountRate",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedRenewalTerm1": {
     "auth_ref": [
      "r421"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Term of lessee's operating lease renewal for lease not yet commenced, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Lessee, Operating Lease, Lease Not yet Commenced, Renewal Term",
        "terseLabel": "Renewal term"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLeaseNotYetCommencedRenewalTerm1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedTermOfContract1": {
     "auth_ref": [
      "r421"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Term of lessee's operating lease not yet commenced, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Lessee, Operating Lease, Lease Not yet Commenced, Term of Contract",
        "terseLabel": "Lease term"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLeaseNotYetCommencedTermOfContract1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityMaturityTableTextBlock": {
     "auth_ref": [
      "r431"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of undiscounted cash flows of lessee's operating lease liability. Includes, but is not limited to, reconciliation of undiscounted cash flows to operating lease liability recognized in statement of financial position.",
        "label": "Lessee, Operating Lease, Liability, Maturity [Table Text Block]",
        "verboseLabel": "Operating Lease Maturity"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityMaturityTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails_1": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease.",
        "label": "Lessee, Operating Lease, Liability, to be Paid",
        "terseLabel": "Future lease commitment",
        "totalLabel": "Total minimum lease payments"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease to be paid in next fiscal year following current fiscal year. Excludes interim and annual periods when interim periods are reported from current statement of financial position date (rolling approach).",
        "label": "Lessee, Operating Lease, Liability, to be Paid, Year One",
        "terseLabel": "2022"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 5.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease to be paid in fourth fiscal year following current fiscal year. Excludes interim and annual periods when interim periods are reported from current statement of financial position date (rolling approach).",
        "label": "Lessee, Operating Lease, Liability, to be Paid, Year Four",
        "terseLabel": "2025"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDueYearFour",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 4.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease to be paid in third fiscal year following current fiscal year. Excludes interim and annual periods when interim periods are reported from current statement of financial position date (rolling approach).",
        "label": "Lessee, Operating Lease, Liability, to be Paid, Year Three",
        "terseLabel": "2024"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDueYearThree",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 3.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease to be paid in second fiscal year following current fiscal year. Excludes interim and annual periods when interim periods are reported from current statement of financial position date (rolling approach).",
        "label": "Lessee, Operating Lease, Liability, to be Paid, Year Two",
        "terseLabel": "2023"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDueYearTwo",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payment for operating lease having initial or remaining lease term in excess of one year to be paid in remainder of current fiscal year.",
        "label": "Lessee, Operating Lease, Liability, to be Paid, Remainder of Fiscal Year",
        "terseLabel": "2021 (remaining 3 months)"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount": {
     "auth_ref": [
      "r431"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails_1": {
       "order": 1.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's undiscounted obligation for lease payments in excess of discounted obligation for lease payments for operating lease.",
        "label": "Lessee, Operating Lease, Liability, Undiscounted Excess Amount",
        "terseLabel": "Less: imputed interest"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityUndiscountedExcessAmount",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseRenewalTerm": {
     "auth_ref": [
      "r420"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Term of lessee's operating lease renewal, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Lessee, Operating Lease, Renewal Term",
        "terseLabel": "Renewal term"
       }
      }
     },
     "localname": "LesseeOperatingLeaseRenewalTerm",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_Liabilities": {
     "auth_ref": [
      "r39",
      "r98",
      "r180",
      "r217",
      "r266",
      "r267",
      "r268",
      "r271",
      "r272",
      "r273",
      "r275",
      "r277",
      "r279",
      "r280",
      "r392",
      "r393",
      "r394",
      "r407",
      "r443",
      "r444"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_LiabilitiesAndStockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sum of the carrying amounts as of the balance sheet date of all liabilities that are recognized. Liabilities are probable future sacrifices of economic benefits arising from present obligations of an entity to transfer assets or provide services to other entities in the future.",
        "label": "Liabilities",
        "totalLabel": "Total liabilities"
       }
      }
     },
     "localname": "Liabilities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LiabilitiesAndStockholdersEquity": {
     "auth_ref": [
      "r26",
      "r98",
      "r217",
      "r407",
      "r445",
      "r467",
      "r484"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of liabilities and equity items, including the portion of equity attributable to noncontrolling interests, if any.",
        "label": "Liabilities and Equity",
        "totalLabel": "Total liabilities and stockholders' equity"
       }
      }
     },
     "localname": "LiabilitiesAndStockholdersEquity",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LiabilitiesAndStockholdersEquityAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities and Equity [Abstract]",
        "verboseLabel": "Liabilities and Stockholders' Equity"
       }
      }
     },
     "localname": "LiabilitiesAndStockholdersEquityAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LiabilitiesCurrent": {
     "auth_ref": [
      "r41",
      "r98",
      "r217",
      "r266",
      "r267",
      "r268",
      "r271",
      "r272",
      "r273",
      "r275",
      "r277",
      "r279",
      "r280",
      "r392",
      "r393",
      "r394",
      "r407",
      "r443",
      "r444",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_Liabilities",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total obligations incurred as part of normal operations that are expected to be paid during the following twelve months or within one business cycle, if longer.",
        "label": "Liabilities, Current",
        "totalLabel": "Total current liabilities"
       }
      }
     },
     "localname": "LiabilitiesCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LiabilitiesCurrentAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities, Current [Abstract]",
        "verboseLabel": "Current liabilities:"
       }
      }
     },
     "localname": "LiabilitiesCurrentAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity": {
     "auth_ref": [
      "r38"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Maximum borrowing capacity under the credit facility without consideration of any current restrictions on the amount that could be borrowed or the amounts currently outstanding under the facility.",
        "label": "Line of Credit Facility, Maximum Borrowing Capacity",
        "terseLabel": "Borrowing capacity"
       }
      }
     },
     "localname": "LineOfCreditFacilityMaximumBorrowingCapacity",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LossContingenciesByNatureOfContingencyAxis": {
     "auth_ref": [
      "r254",
      "r255",
      "r256",
      "r257",
      "r258",
      "r259",
      "r260",
      "r263",
      "r264"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of existing condition, situation, or set of circumstances involving uncertainty as to possible loss to an enterprise that will ultimately be resolved when one or more future events occur or fail to occur.",
        "label": "Loss Contingency Nature [Axis]",
        "terseLabel": "Loss Contingency Nature [Axis]"
       }
      }
     },
     "localname": "LossContingenciesByNatureOfContingencyAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LossContingencyAccrualCarryingValueCurrent": {
     "auth_ref": [
      "r254"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of loss contingency liability expected to be resolved within one year or the normal operating cycle, if longer.",
        "label": "Loss Contingency, Accrual, Current",
        "terseLabel": "Loss contingency accrual"
       }
      }
     },
     "localname": "LossContingencyAccrualCarryingValueCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LossContingencyNatureDomain": {
     "auth_ref": [
      "r254",
      "r255",
      "r256",
      "r257",
      "r258",
      "r259",
      "r260",
      "r263",
      "r264"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "An existing condition, situation, or set of circumstances involving uncertainty as to possible loss to an enterprise that will ultimately be resolved when one or more future events occur or fail to occur. Resolution of the uncertainty may confirm the incurrence of a loss or impairment of an asset or the incurrence of a liability.",
        "label": "Loss Contingency, Nature [Domain]",
        "terseLabel": "Loss Contingency, Nature [Domain]"
       }
      }
     },
     "localname": "LossContingencyNatureDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_MarketableSecuritiesLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Marketable Securities [Line Items]",
        "terseLabel": "Marketable Securities [Line Items]"
       }
      }
     },
     "localname": "MarketableSecuritiesLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_MarketableSecuritiesTable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about investment in marketable security.",
        "label": "Marketable Securities [Table]",
        "terseLabel": "Marketable Securities [Table]"
       }
      }
     },
     "localname": "MarketableSecuritiesTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_MoneyMarketFundsMember": {
     "auth_ref": [
      "r348"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Fund that invests in short-term money-market instruments, for example, but not limited to, commercial paper, banker's acceptances, repurchase agreements, government securities, certificates of deposit, and other highly liquid securities.",
        "label": "Money Market Funds [Member]",
        "terseLabel": "Money Market Funds"
       }
      }
     },
     "localname": "MoneyMarketFundsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_NatureOfOperations": {
     "auth_ref": [
      "r138",
      "r152"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for the nature of an entity's business, major products or services, principal markets including location, and the relative importance of its operations in each business and the basis for the determination, including but not limited to, assets, revenues, or earnings. For an entity that has not commenced principal operations, disclosures about the risks and uncertainties related to the activities in which the entity is currently engaged and an understanding of what those activities are being directed toward.",
        "label": "Nature of Operations [Text Block]",
        "verboseLabel": "Description of Business"
       }
      }
     },
     "localname": "NatureOfOperations",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusiness"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_NetCashProvidedByUsedInFinancingActivities": {
     "auth_ref": [
      "r80"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash inflow (outflow) from financing activities, including discontinued operations. Financing activity cash flows include obtaining resources from owners and providing them with a return on, and a return of, their investment; borrowing money and repaying amounts borrowed, or settling the obligation; and obtaining and paying for other resources obtained from creditors on long-term credit.",
        "label": "Net Cash Provided by (Used in) Financing Activities",
        "totalLabel": "Net cash provided by (used in) financing activities"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInFinancingActivities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NetCashProvidedByUsedInFinancingActivitiesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Cash Provided by (Used in) Financing Activities [Abstract]",
        "verboseLabel": "Financing activities:"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInFinancingActivitiesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetCashProvidedByUsedInInvestingActivities": {
     "auth_ref": [
      "r80"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash inflow (outflow) from investing activities, including discontinued operations. Investing activity cash flows include making and collecting loans and acquiring and disposing of debt or equity instruments and property, plant, and equipment and other productive assets.",
        "label": "Net Cash Provided by (Used in) Investing Activities",
        "totalLabel": "Net cash used in investing activities"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInInvestingActivities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NetCashProvidedByUsedInInvestingActivitiesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Cash Provided by (Used in) Investing Activities [Abstract]",
        "verboseLabel": "Investing activities:"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInInvestingActivitiesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetCashProvidedByUsedInOperatingActivities": {
     "auth_ref": [
      "r80",
      "r85",
      "r88"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect",
       "weight": 1.0
      }
     },
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash inflow (outflow) from operating activities, including discontinued operations. Operating activity cash flows include transactions, adjustments, and changes in value not defined as investing or financing activities.",
        "label": "Net Cash Provided by (Used in) Operating Activities",
        "totalLabel": "Net cash used in operating activities"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInOperatingActivities",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NetCashProvidedByUsedInOperatingActivitiesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Cash Provided by (Used in) Operating Activities [Abstract]",
        "verboseLabel": "Operating activities:"
       }
      }
     },
     "localname": "NetCashProvidedByUsedInOperatingActivitiesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetIncomeLoss": {
     "auth_ref": [
      "r2",
      "r57",
      "r58",
      "r61",
      "r63",
      "r88",
      "r98",
      "r108",
      "r110",
      "r111",
      "r112",
      "r113",
      "r116",
      "r117",
      "r124",
      "r166",
      "r178",
      "r182",
      "r185",
      "r188",
      "r217",
      "r266",
      "r267",
      "r268",
      "r271",
      "r272",
      "r273",
      "r275",
      "r277",
      "r279",
      "r280",
      "r398",
      "r407",
      "r472",
      "r490"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      },
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The portion of profit or loss for the period, net of income taxes, which is attributable to the parent.",
        "label": "Net Income (Loss) Attributable to Parent",
        "terseLabel": "Net loss",
        "totalLabel": "Net income (loss)",
        "verboseLabel": "Net income (loss)"
       }
      }
     },
     "localname": "NetIncomeLoss",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited",
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NewAccountingPronouncementsPolicyPolicyTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of accounting policy pertaining to new accounting pronouncements that may impact the entity's financial reporting. Includes, but is not limited to, quantification of the expected or actual impact.",
        "label": "New Accounting Pronouncements, Policy [Policy Text Block]",
        "verboseLabel": "Accounting Pronouncements"
       }
      }
     },
     "localname": "NewAccountingPronouncementsPolicyPolicyTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_NoncashOrPartNoncashAcquisitionNoncashFinancialOrEquityInstrumentConsiderationSharesIssued1": {
     "auth_ref": [
      "r91",
      "r92",
      "r93"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The number of shares issued as [noncash or part noncash] consideration for a business or asset acquired. Noncash is defined as transactions during a period that affect recognized assets or liabilities but that do not result in cash receipts or cash payments in the period. \"Part noncash\" refers to that portion of the transaction not resulting in cash receipts or cash payments in the period.",
        "label": "Noncash or Part Noncash Acquisition, Noncash Financial or Equity Instrument Consideration, Shares Issued",
        "terseLabel": "Number of shares received in exchange for services (in shares)"
       }
      }
     },
     "localname": "NoncashOrPartNoncashAcquisitionNoncashFinancialOrEquityInstrumentConsiderationSharesIssued1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_NoncurrentAssets": {
     "auth_ref": [
      "r193"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Long-lived assets other than financial instruments, long-term customer relationships of a financial institution, mortgage and other servicing rights, deferred policy acquisition costs, and deferred tax assets.",
        "label": "Long-Lived Assets",
        "terseLabel": "Long-lived assets"
       }
      }
     },
     "localname": "NoncurrentAssets",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NonmonetaryTransactionGrossOperatingRevenueRecognized": {
     "auth_ref": [
      "r433"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of gross operating revenue recognized in a nonmonetary transaction.",
        "label": "Nonmonetary Transaction, Gross Operating Revenue Recognized",
        "terseLabel": "Research and development revenue from transactions with MAI"
       }
      }
     },
     "localname": "NonmonetaryTransactionGrossOperatingRevenueRecognized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NotesReceivableGross": {
     "auth_ref": [
      "r203",
      "r219",
      "r223",
      "r226",
      "r230",
      "r231",
      "r545",
      "r546",
      "r547"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_AccountsNotesAndLoansReceivableNetCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount, before allowance for credit loss, of financing receivable.",
        "label": "Financing Receivable, before Allowance for Credit Loss",
        "totalLabel": "Total financial assets"
       }
      }
     },
     "localname": "NotesReceivableGross",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NumberOfOperatingSegments": {
     "auth_ref": [
      "r154"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of operating segments. An operating segment is a component of an enterprise: (a) that engages in business activities from which it may earn revenues and incur expenses (including revenues and expenses relating to transactions with other components of the same enterprise), (b) whose operating results are regularly reviewed by the enterprise's chief operating decision maker to make decisions about resources to be allocated to the segment and assess its performance, and (c) for which discrete financial information is available. An operating segment may engage in business activities for which it has yet to earn revenues, for example, start-up operations may be operating segments before earning revenues.",
        "label": "Number of Operating Segments",
        "terseLabel": "Number of operating segments"
       }
      }
     },
     "localname": "NumberOfOperatingSegments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationNarrativeDetails"
     ],
     "xbrltype": "integerItemType"
    },
    "us-gaap_NumberOfReportableSegments": {
     "auth_ref": [
      "r154"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of segments reported by the entity. A reportable segment is a component of an entity for which there is an accounting requirement to report separate financial information on that component in the entity's financial statements.",
        "label": "Number of Reportable Segments",
        "terseLabel": "Number of reportable segments"
       }
      }
     },
     "localname": "NumberOfReportableSegments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationNarrativeDetails"
     ],
     "xbrltype": "integerItemType"
    },
    "us-gaap_OperatingCostsAndExpensesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Operating Costs and Expenses [Abstract]",
        "verboseLabel": "Costs and operating expenses:"
       }
      }
     },
     "localname": "OperatingCostsAndExpensesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OperatingIncomeLoss": {
     "auth_ref": [
      "r166",
      "r178",
      "r182",
      "r185",
      "r188"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The net result for the period of deducting operating expenses from operating revenues.",
        "label": "Operating Income (Loss)",
        "totalLabel": "Income (loss) from operations",
        "verboseLabel": "Income (loss) from operations"
       }
      }
     },
     "localname": "OperatingIncomeLoss",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseCost": {
     "auth_ref": [
      "r423",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_LeaseCost",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of single lease cost, calculated by allocation of remaining cost of lease over remaining lease term. Includes, but is not limited to, single lease cost, after impairment of right-of-use asset, calculated by amortization of remaining right-of-use asset and accretion of lease liability.",
        "label": "Operating Lease, Cost",
        "terseLabel": "Operating lease cost"
       }
      }
     },
     "localname": "OperatingLeaseCost",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseLiabilitiesPaymentsDueAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Lessee, Operating Lease, Liability, Payment, Due [Abstract]",
        "terseLabel": "Operating Leases"
       }
      }
     },
     "localname": "OperatingLeaseLiabilitiesPaymentsDueAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OperatingLeaseLiability": {
     "auth_ref": [
      "r416"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails_1": {
       "order": 2.0,
       "parentTag": "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Present value of lessee's discounted obligation for lease payments from operating lease.",
        "label": "Operating Lease, Liability",
        "verboseLabel": "Lease obligations"
       }
      }
     },
     "localname": "OperatingLeaseLiability",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseLiabilityCurrent": {
     "auth_ref": [
      "r416"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_LiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Present value of lessee's discounted obligation for lease payments from operating lease, classified as current.",
        "label": "Operating Lease, Liability, Current",
        "terseLabel": "Current portion of lease obligations - Operating leases"
       }
      }
     },
     "localname": "OperatingLeaseLiabilityCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseLiabilityNoncurrent": {
     "auth_ref": [
      "r416"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_Liabilities",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Present value of lessee's discounted obligation for lease payments from operating lease, classified as noncurrent.",
        "label": "Operating Lease, Liability, Noncurrent",
        "terseLabel": "Long-term lease obligations - Operating leases"
       }
      }
     },
     "localname": "OperatingLeaseLiabilityNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeasePayments": {
     "auth_ref": [
      "r419",
      "r427"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash outflow from operating lease, excluding payments to bring another asset to condition and location necessary for its intended use.",
        "label": "Operating Lease, Payments",
        "terseLabel": "Operating cash flows from operating leases"
       }
      }
     },
     "localname": "OperatingLeasePayments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesCashPaidforLeaseObligationsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseRightOfUseAsset": {
     "auth_ref": [
      "r415"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of lessee's right to use underlying asset under operating lease.",
        "label": "Operating Lease, Right-of-Use Asset",
        "terseLabel": "Right-of-use assets - Operating leases, net"
       }
      }
     },
     "localname": "OperatingLeaseRightOfUseAsset",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseRightOfUseAssetAmortizationExpense": {
     "auth_ref": [
      "r87"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of amortization expense for right-of-use asset from operating lease.",
        "label": "Operating Lease, Right-of-Use Asset, Amortization Expense",
        "terseLabel": "Amortization expense - right-of-use assets - operating and finance leases"
       }
      }
     },
     "localname": "OperatingLeaseRightOfUseAssetAmortizationExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseWeightedAverageDiscountRatePercent": {
     "auth_ref": [
      "r429",
      "r432"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Weighted average discount rate for operating lease calculated at point in time.",
        "label": "Operating Lease, Weighted Average Discount Rate, Percent",
        "verboseLabel": "Weighted-average discount rate"
       }
      }
     },
     "localname": "OperatingLeaseWeightedAverageDiscountRatePercent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherLeaseInformationDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_OperatingLeaseWeightedAverageRemainingLeaseTerm1": {
     "auth_ref": [
      "r428",
      "r432"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Weighted average remaining lease term for operating lease, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Operating Lease, Weighted Average Remaining Lease Term",
        "terseLabel": "Weighted-average remaining lease term"
       }
      }
     },
     "localname": "OperatingLeaseWeightedAverageRemainingLeaseTerm1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherLeaseInformationDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_OperatingSegmentsMember": {
     "auth_ref": [
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r188"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Identifies components of an entity that engage in business activities from which they may earn revenue and incur expenses, including transactions with other components of the same entity.",
        "label": "Operating Segments [Member]",
        "terseLabel": "Operating Segments",
        "verboseLabel": "Operating segments"
       }
      }
     },
     "localname": "OperatingSegmentsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_OrganizationConsolidationAndPresentationOfFinancialStatementsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Organization, Consolidation and Presentation of Financial Statements [Abstract]",
        "terseLabel": "Organization, Consolidation and Presentation of Financial Statements [Abstract]"
       }
      }
     },
     "localname": "OrganizationConsolidationAndPresentationOfFinancialStatementsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_OtherAccruedLiabilitiesCurrentAndNoncurrent": {
     "auth_ref": [
      "r469",
      "r489"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": 3.0,
       "parentTag": "us-gaap_AccruedLiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of expenses incurred but not yet paid classified as other.",
        "label": "Other Accrued Liabilities",
        "terseLabel": "Other"
       }
      }
     },
     "localname": "OtherAccruedLiabilitiesCurrentAndNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherAssetsNoncurrent": {
     "auth_ref": [
      "r36"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 8.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of noncurrent assets classified as other.",
        "label": "Other Assets, Noncurrent",
        "verboseLabel": "Other non-current assets"
       }
      }
     },
     "localname": "OtherAssetsNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherCommitmentsLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Other Commitments [Line Items]",
        "terseLabel": "Other Commitments [Line Items]"
       }
      }
     },
     "localname": "OtherCommitmentsLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OtherCommitmentsTable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about obligations resulting from other commitments.",
        "label": "Other Commitments [Table]",
        "terseLabel": "Other Commitments [Table]"
       }
      }
     },
     "localname": "OtherCommitmentsTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OtherLiabilitiesNoncurrent": {
     "auth_ref": [
      "r43"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_Liabilities",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of liabilities classified as other, due after one year or the normal operating cycle, if longer.",
        "label": "Other Liabilities, Noncurrent",
        "verboseLabel": "Other long-term liabilities"
       }
      }
     },
     "localname": "OtherLiabilitiesNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherNoncashIncome": {
     "auth_ref": [
      "r88"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 6.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of income or gain included in net income that result in no cash inflow (outflow), classified as other.",
        "label": "Other Noncash Income",
        "negatedTerseLabel": "Equity securities earned from research and development activities"
       }
      }
     },
     "localname": "OtherNoncashIncome",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherNonoperatingIncomeExpense": {
     "auth_ref": [
      "r72"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of income (expense) related to nonoperating activities, classified as other.",
        "label": "Other Nonoperating Income (Expense)",
        "terseLabel": "Other income (expense), net"
       }
      }
     },
     "localname": "OtherNonoperatingIncomeExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherOperatingActivitiesCashFlowStatement": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 8.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Other cash or noncash adjustments to reconcile net income to cash provided by (used in) operating activities that are not separately disclosed in the statement of cash flows (for example,  cash received or cash paid during the current period for miscellaneous operating activities, net change during the reporting period in other assets or other liabilities).",
        "label": "Other Operating Activities, Cash Flow Statement",
        "terseLabel": "Other non-cash items"
       }
      }
     },
     "localname": "OtherOperatingActivitiesCashFlowStatement",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PastDueFinancingReceivablesTableTextBlock": {
     "auth_ref": [
      "r202",
      "r203",
      "r223",
      "r231"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of aging analysis for financing receivable.",
        "label": "Financing Receivable, Past Due [Table Text Block]",
        "terseLabel": "Summary of Accounts Receivable by Aging Category"
       }
      }
     },
     "localname": "PastDueFinancingReceivablesTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_PaymentsForRent": {
     "auth_ref": [
      "r84"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Cash payments to lessor's for use of assets under operating leases.",
        "label": "Payments for Rent",
        "terseLabel": "Annualized rent"
       }
      }
     },
     "localname": "PaymentsForRent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsOfStockIssuanceCosts": {
     "auth_ref": [
      "r78"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInFinancingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cash outflow for cost incurred directly with the issuance of an equity security.",
        "label": "Payments of Stock Issuance Costs",
        "negatedTerseLabel": "Costs incurred in connection with equity financing"
       }
      }
     },
     "localname": "PaymentsOfStockIssuanceCosts",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation": {
     "auth_ref": [
      "r77"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInFinancingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash outflow to satisfy grantee's tax withholding obligation for award under share-based payment arrangement.",
        "label": "Payment, Tax Withholding, Share-based Payment Arrangement",
        "negatedTerseLabel": "Taxes paid related to net share settlement of equity awards"
       }
      }
     },
     "localname": "PaymentsRelatedToTaxWithholdingForShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsToAcquireOtherInvestments": {
     "auth_ref": [
      "r75"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInInvestingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash outflow to acquire investments classified as other.",
        "label": "Payments to Acquire Other Investments",
        "negatedTerseLabel": "Investment in equity securities",
        "terseLabel": "Payments to acquire other investments"
       }
      }
     },
     "localname": "PaymentsToAcquireOtherInvestments",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited",
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsToAcquirePropertyPlantAndEquipment": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInInvestingActivities",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cash outflow associated with the acquisition of long-lived, physical assets that are used in the normal conduct of business to produce goods and services and not intended for resale; includes cash outflows to pay for construction of self-constructed assets.",
        "label": "Payments to Acquire Property, Plant, and Equipment",
        "negatedLabel": "Purchase of property and equipment"
       }
      }
     },
     "localname": "PaymentsToAcquirePropertyPlantAndEquipment",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PerformanceSharesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based payment arrangement awarded for meeting performance target.",
        "label": "Performance Shares [Member]",
        "terseLabel": "Performance Shares"
       }
      }
     },
     "localname": "PerformanceSharesMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PlanNameAxis": {
     "auth_ref": [
      "r365",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by plan name for share-based payment arrangement.",
        "label": "Plan Name [Axis]",
        "terseLabel": "Plan Name [Axis]"
       }
      }
     },
     "localname": "PlanNameAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_PlanNameDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Plan name for share-based payment arrangement.",
        "label": "Plan Name [Domain]",
        "terseLabel": "Plan Name [Domain]"
       }
      }
     },
     "localname": "PlanNameDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PreferredStockParOrStatedValuePerShare": {
     "auth_ref": [
      "r18",
      "r298"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Face amount or stated value per share of preferred stock nonredeemable or redeemable solely at the option of the issuer.",
        "label": "Preferred Stock, Par or Stated Value Per Share",
        "terseLabel": "Preferred stock, par value (in usd per share)"
       }
      }
     },
     "localname": "PreferredStockParOrStatedValuePerShare",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_PreferredStockSharesAuthorized": {
     "auth_ref": [
      "r18"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The maximum number of nonredeemable preferred shares (or preferred stock redeemable solely at the option of the issuer) permitted to be issued by an entity's charter and bylaws.",
        "label": "Preferred Stock, Shares Authorized",
        "terseLabel": "Preferred stock, shares authorized (in shares)"
       }
      }
     },
     "localname": "PreferredStockSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockSharesIssued": {
     "auth_ref": [
      "r18",
      "r298"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total number of nonredeemable preferred shares (or preferred stock redeemable solely at the option of the issuer) issued to shareholders (includes related preferred shares that were issued, repurchased, and remain in the treasury). May be all or portion of the number of preferred shares authorized. Excludes preferred shares that are classified as debt.",
        "label": "Preferred Stock, Shares Issued",
        "terseLabel": "Preferred stock, shares issued (in shares)"
       }
      }
     },
     "localname": "PreferredStockSharesIssued",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockSharesOutstanding": {
     "auth_ref": [
      "r18"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Aggregate share number for all nonredeemable preferred stock (or preferred stock redeemable solely at the option of the issuer) held by stockholders. Does not include preferred shares that have been repurchased.",
        "label": "Preferred Stock, Shares Outstanding",
        "terseLabel": "Preferred stock, shares outstanding (in shares)"
       }
      }
     },
     "localname": "PreferredStockSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnauditedParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockValue": {
     "auth_ref": [
      "r18",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_StockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Aggregate par or stated value of issued nonredeemable preferred stock (or preferred stock redeemable solely at the option of the issuer). This item includes treasury stock repurchased by the entity. Note: elements for number of nonredeemable preferred shares, par value and other disclosure concepts are in another section within stockholders' equity.",
        "label": "Preferred Stock, Value, Issued",
        "terseLabel": "Preferred stock, $0.0001 par value per share; 5,000 shares authorized, none issued and outstanding"
       }
      }
     },
     "localname": "PreferredStockValue",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PrepaidExpenseAndOtherAssetsCurrent": {
     "auth_ref": [
      "r6",
      "r31",
      "r32"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 6.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of asset related to consideration paid in advance for costs that provide economic benefits in future periods, and amount of other assets that are expected to be realized or consumed within one year or the normal operating cycle, if longer.",
        "label": "Prepaid Expense and Other Assets, Current",
        "verboseLabel": "Prepaid expenses and other current assets"
       }
      }
     },
     "localname": "PrepaidExpenseAndOtherAssetsCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromCollaborators": {
     "auth_ref": [
      "r81"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Cash received from collaborators during the current period.",
        "label": "Proceeds from Collaborators",
        "terseLabel": "Non-refundable cash payment"
       }
      }
     },
     "localname": "ProceedsFromCollaborators",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment": {
     "auth_ref": [
      "r73"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInInvestingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cash inflow from the sale of long-lived, physical assets that are used in the normal conduct of business to produce goods and services and not intended for resale.",
        "label": "Proceeds from Sale of Property, Plant, and Equipment",
        "terseLabel": "Proceeds from sale of property and equipment"
       }
      }
     },
     "localname": "ProceedsFromSaleOfPropertyPlantAndEquipment",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromStockOptionsExercised": {
     "auth_ref": [
      "r76",
      "r375"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInFinancingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash inflow from exercise of option under share-based payment arrangement.",
        "label": "Proceeds from Stock Options Exercised",
        "terseLabel": "Proceeds from exercises of stock options",
        "verboseLabel": "Proceeds from exercises of stock options"
       }
      }
     },
     "localname": "ProceedsFromStockOptionsExercised",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentByTypeAxis": {
     "auth_ref": [
      "r35",
      "r244"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of long-lived, physical assets used to produce goods and services and not intended for resale.",
        "label": "Long-Lived Tangible Asset [Axis]",
        "terseLabel": "Property, Plant and Equipment, Type [Axis]"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentByTypeAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentGross": {
     "auth_ref": [
      "r34",
      "r242"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_PropertyPlantAndEquipmentNet",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount before accumulated depreciation, depletion and amortization of physical assets used in the normal conduct of business and not intended for resale. Examples include, but are not limited to, land, buildings, machinery and equipment, office equipment, and furniture and fixtures.",
        "label": "Property, Plant and Equipment, Gross",
        "terseLabel": "Property and equipment"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentGross",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Property, Plant and Equipment [Line Items]",
        "terseLabel": "Property, Plant and Equipment [Line Items]"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentNet": {
     "auth_ref": [
      "r12",
      "r13",
      "r244",
      "r445",
      "r477",
      "r486"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 6.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount after accumulated depreciation, depletion and amortization of physical assets used in the normal conduct of business to produce goods and services and not intended for resale. Examples include, but are not limited to, land, buildings, machinery and equipment, office equipment, and furniture and fixtures.",
        "label": "Property, Plant and Equipment, Net",
        "totalLabel": "Property and equipment, net",
        "verboseLabel": "Property and equipment, net"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentNet",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentTextBlock": {
     "auth_ref": [
      "r12",
      "r244"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of physical assets used in the normal conduct of business and not intended for resale. Includes, but is not limited to, balances by class of assets, depreciation and depletion expense and method used, including composite depreciation, and accumulated deprecation.",
        "label": "Property, Plant and Equipment [Table Text Block]",
        "terseLabel": "Schedule of Property and Equipment, Net"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentTypeDomain": {
     "auth_ref": [
      "r12",
      "r242"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Listing of long-lived, physical assets that are used in the normal conduct of business to produce goods and services and not intended for resale. Examples include land, buildings, machinery and equipment, and other types of furniture and equipment including, but not limited to, office equipment, furniture and fixtures, and computer equipment and software.",
        "label": "Long-Lived Tangible Asset [Domain]",
        "terseLabel": "Property, Plant and Equipment, Type [Domain]"
       }
      }
     },
     "localname": "PropertyPlantAndEquipmentTypeDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ProvisionForDoubtfulAccounts": {
     "auth_ref": [
      "r65",
      "r221"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 5.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of expense (reversal of expense) for expected credit loss on accounts receivable.",
        "label": "Accounts Receivable, Credit Loss Expense (Reversal)",
        "terseLabel": "Allowance for credit losses"
       }
      }
     },
     "localname": "ProvisionForDoubtfulAccounts",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PurchaseObligation": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_AccruedLiabilitiesCurrent",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Minimum amount of purchase arrangement in which the entity has agreed to expend funds to procure goods or services from a supplier.",
        "label": "Purchase Obligation",
        "terseLabel": "Accrued purchases"
       }
      }
     },
     "localname": "PurchaseObligation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ReceivablesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Receivables [Abstract]"
       }
      }
     },
     "localname": "ReceivablesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_ReconciliationOfRevenueFromSegmentsToConsolidatedTextBlock": {
     "auth_ref": [
      "r177",
      "r182"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of all significant reconciling items in the reconciliation of total revenues from reportable segments to the entity's consolidated revenues.",
        "label": "Reconciliation of Revenue from Segments to Consolidated [Table Text Block]",
        "verboseLabel": "Schedule of Revenues by Geographical Area"
       }
      }
     },
     "localname": "ReconciliationOfRevenueFromSegmentsToConsolidatedTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_RelatedPartyTransactionAxis": {
     "auth_ref": [
      "r355",
      "r436",
      "r437",
      "r440"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by type of related party transaction.",
        "label": "Related Party Transaction [Axis]",
        "terseLabel": "Related Party Transaction [Axis]"
       }
      }
     },
     "localname": "RelatedPartyTransactionAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RelatedPartyTransactionDomain": {
     "auth_ref": [
      "r355"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Transaction between related party.",
        "label": "Related Party Transaction [Domain]",
        "terseLabel": "Related Party Transaction [Domain]"
       }
      }
     },
     "localname": "RelatedPartyTransactionDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RelatedPartyTransactionLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Related Party Transaction [Line Items]",
        "terseLabel": "Related Party Transaction [Line Items]"
       }
      }
     },
     "localname": "RelatedPartyTransactionLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RelatedPartyTransactionsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Related Party Transactions [Abstract]"
       }
      }
     },
     "localname": "RelatedPartyTransactionsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_RelatedPartyTransactionsDisclosureTextBlock": {
     "auth_ref": [
      "r434",
      "r435",
      "r437",
      "r441",
      "r442"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for related party transactions. Examples of related party transactions include transactions between (a) a parent company and its subsidiary; (b) subsidiaries of a common parent; (c) and entity and its principal owners; and (d) affiliates.",
        "label": "Related Party Transactions Disclosure [Text Block]",
        "terseLabel": "Related Party Transactions"
       }
      }
     },
     "localname": "RelatedPartyTransactionsDisclosureTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactions"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ResearchAndDevelopmentExpense": {
     "auth_ref": [
      "r384",
      "r458",
      "r527"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_CostsAndExpenses",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The aggregate costs incurred (1) in a planned search or critical investigation aimed at discovery of new knowledge with the hope that such knowledge will be useful in developing a new product or service, a new process or technique, or in bringing about a significant improvement to an existing product or process; or (2) to translate research findings or other knowledge into a plan or design for a new product or process or for a significant improvement to an existing product or process whether intended for sale or the entity's use, during the reporting period charged to research and development projects, including the costs of developing computer software up to the point in time of achieving technological feasibility, and costs allocated in accounting for a business combination to in-process projects deemed to have no alternative future use.",
        "label": "Research and Development Expense",
        "verboseLabel": "Research and development"
       }
      }
     },
     "localname": "ResearchAndDevelopmentExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ResearchAndDevelopmentExpenseMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Primary financial statement caption in which the reported facts about research and development expense have been included.",
        "label": "Research and Development Expense [Member]",
        "verboseLabel": "Research and development"
       }
      }
     },
     "localname": "ResearchAndDevelopmentExpenseMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RestrictedCash": {
     "auth_ref": [
      "r94",
      "r462",
      "r482"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash restricted as to withdrawal or usage. Cash includes, but is not limited to, currency on hand, demand deposits with banks or financial institutions, and other accounts with general characteristics of demand deposits.",
        "label": "Restricted Cash",
        "terseLabel": "Restricted cash, current"
       }
      }
     },
     "localname": "RestrictedCash",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalents": {
     "auth_ref": [
      "r11",
      "r89",
      "r94",
      "r462",
      "r482"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash and cash equivalents restricted as to withdrawal or usage. Cash includes, but is not limited to, currency on hand, demand deposits with banks or financial institutions, and other accounts with general characteristics of demand deposits. Cash equivalents include, but are not limited to, short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Restricted Cash and Cash Equivalents",
        "terseLabel": "Restricted cash, current and non-current"
       }
      }
     },
     "localname": "RestrictedCashAndCashEquivalents",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalentsCashAndCashEquivalentsAxis": {
     "auth_ref": [
      "r33"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by category of cash or cash equivalent items which are restricted as to withdrawal or usage.",
        "label": "Restricted Cash and Cash Equivalents [Axis]",
        "terseLabel": "Restricted Cash and Cash Equivalents [Axis]"
       }
      }
     },
     "localname": "RestrictedCashAndCashEquivalentsCashAndCashEquivalentsAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalentsCashAndCashEquivalentsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Type of cash and cash equivalent. Cash is currency on hand as well as demand deposits with banks or financial institutions. Includes other kinds of accounts that have the general characteristics of demand deposits. Also includes short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Cash and Cash Equivalents [Domain]",
        "terseLabel": "Cash and Cash Equivalents [Domain]"
       }
      }
     },
     "localname": "RestrictedCashAndCashEquivalentsCashAndCashEquivalentsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalentsNoncurrent": {
     "auth_ref": [
      "r8",
      "r14",
      "r89",
      "r94",
      "r511"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_Assets",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash and cash equivalents restricted as to withdrawal or usage, classified as noncurrent. Cash includes, but is not limited to, currency on hand, demand deposits with banks or financial institutions, and other accounts with general characteristics of demand deposits. Cash equivalents include, but are not limited to, short-term, highly liquid investments that are both readily convertible to known amounts of cash and so near their maturity that they present insignificant risk of changes in value because of changes in interest rates.",
        "label": "Restricted Cash and Cash Equivalents, Noncurrent",
        "terseLabel": "Restricted cash"
       }
      }
     },
     "localname": "RestrictedCashAndCashEquivalentsNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndInvestmentsNoncurrent": {
     "auth_ref": [
      "r510",
      "r512"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The noncurrent cash, cash equivalents and investments that is restricted as to withdrawal or usage. Restrictions may include legally restricted deposits held as compensating balances against borrowing arrangements, contracts entered into with others, or entity statements of intention with regard to particular deposits classified as long-term; that is not expected to be released from such existing restrictions within one year of the balance sheet date or operating cycle, whichever is longer. Excludes compensating balance arrangements that are not agreements which legally restrict the use of cash amounts shown on the balance sheet. Includes noncurrent cash equivalents and investments that are similarly restricted as to withdrawal, usage or disposal.",
        "label": "Restricted Cash and Investments, Noncurrent",
        "terseLabel": "Non-current restricted cash"
       }
      }
     },
     "localname": "RestrictedCashAndInvestmentsNoncurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedStockUnitsRSUMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share instrument which is convertible to stock or an equivalent amount of cash, after a specified period of time or when specified performance conditions are met.",
        "label": "Restricted Stock Units (RSUs) [Member]",
        "terseLabel": "RSUs"
       }
      }
     },
     "localname": "RestrictedStockUnitsRSUMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RetainedEarningsAccumulatedDeficit": {
     "auth_ref": [
      "r23",
      "r314",
      "r379",
      "r445",
      "r483",
      "r503",
      "r504"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_StockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cumulative amount of the reporting entity's undistributed earnings or deficit.",
        "label": "Retained Earnings (Accumulated Deficit)",
        "verboseLabel": "Accumulated deficit"
       }
      }
     },
     "localname": "RetainedEarningsAccumulatedDeficit",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RetainedEarningsMember": {
     "auth_ref": [
      "r0",
      "r105",
      "r106",
      "r107",
      "r109",
      "r115",
      "r117",
      "r218",
      "r376",
      "r377",
      "r378",
      "r386",
      "r387",
      "r396",
      "r500",
      "r502"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cumulative amount of the reporting entity's undistributed earnings or deficit.",
        "label": "Retained Earnings [Member]",
        "terseLabel": "Accumulated Deficit"
       }
      }
     },
     "localname": "RetainedEarningsMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RevenueFromContractWithCustomerAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue from Contract with Customer [Abstract]",
        "terseLabel": "Revenue from Contract with Customer [Abstract]"
       }
      }
     },
     "localname": "RevenueFromContractWithCustomerAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax": {
     "auth_ref": [
      "r157",
      "r158",
      "r177",
      "r183",
      "r184",
      "r191",
      "r192",
      "r195",
      "r332",
      "r334",
      "r459"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 1.0,
       "parentTag": "us-gaap_OperatingIncomeLoss",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Revenue from Contract with Customer, Excluding Assessed Tax",
        "terseLabel": "Total revenues"
       }
      }
     },
     "localname": "RevenueFromContractWithCustomerExcludingAssessedTax",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RevenueFromContractWithCustomerTextBlock": {
     "auth_ref": [
      "r322",
      "r323",
      "r324",
      "r325",
      "r326",
      "r327",
      "r330",
      "r331",
      "r337",
      "r346"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure of revenue from contract with customer to transfer good or service and to transfer nonfinancial asset. Includes, but is not limited to, disaggregation of revenue, credit loss recognized from contract with customer, judgment and change in judgment related to contract with customer, and asset recognized from cost incurred to obtain or fulfill contract with customer. Excludes insurance and lease contracts.",
        "label": "Revenue from Contract with Customer [Text Block]",
        "terseLabel": "Revenue Recognition"
       }
      }
     },
     "localname": "RevenueFromContractWithCustomerTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognition"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_RevenueFromRelatedParties": {
     "auth_ref": [
      "r67",
      "r269",
      "r271",
      "r272",
      "r278",
      "r279",
      "r280",
      "r507"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Revenue from Related Parties",
        "terseLabel": "Revenue from related parties"
       }
      }
     },
     "localname": "RevenueFromRelatedParties",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Revenue, Initial Application Period Cumulative Effect Transition [Line Items]",
        "terseLabel": "Revenue, Initial Application Period Cumulative Effect Transition [Line Items]"
       }
      }
     },
     "localname": "RevenueInitialApplicationPeriodCumulativeEffectTransitionLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable": {
     "auth_ref": [
      "r345"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information when using transition method for cumulative effect in initial period of application for revenue from contract with customer.",
        "label": "Revenue, Initial Application Period Cumulative Effect Transition [Table]",
        "terseLabel": "Revenue, Initial Application Period Cumulative Effect Transition [Table]"
       }
      }
     },
     "localname": "RevenueInitialApplicationPeriodCumulativeEffectTransitionTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligation": {
     "auth_ref": [
      "r328"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of transaction price allocated to performance obligation that has not been recognized as revenue.",
        "label": "Revenue, Remaining Performance Obligation, Amount",
        "terseLabel": "Performance obligation"
       }
      }
     },
     "localname": "RevenueRemainingPerformanceObligation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod1": {
     "auth_ref": [
      "r329"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Period in which remaining performance obligation is expected to be recognized as revenue, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days.",
        "label": "Revenue, Remaining Performance Obligation, Expected Timing of Satisfaction, Period",
        "terseLabel": "Expected timing of satisfaction, period"
       }
      }
     },
     "localname": "RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionStartDateAxis": {
     "auth_ref": [
      "r329"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Start date of time band for expected timing of satisfaction of remaining performance obligation, in YYYY-MM-DD format.",
        "label": "Revenue, Remaining Performance Obligation, Expected Timing of Satisfaction, Start Date [Axis]",
        "terseLabel": "Revenue, Remaining Performance Obligation, Expected Timing of Satisfaction, Start Date [Axis]"
       }
      }
     },
     "localname": "RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionStartDateAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock": {
     "auth_ref": [
      "r329"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of expected timing for satisfying remaining performance obligation.",
        "label": "Revenue, Remaining Performance Obligation, Expected Timing of Satisfaction [Table Text Block]",
        "terseLabel": "Performance Obligation, Expected Timing of Satisfaction"
       }
      }
     },
     "localname": "RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_RevenuesAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenues [Abstract]",
        "verboseLabel": "Revenues:"
       }
      }
     },
     "localname": "RevenuesAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevolvingCreditFacilityMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Arrangement in which loan proceeds can continuously be obtained following repayments, but the total amount borrowed cannot exceed a specified maximum amount.",
        "label": "Revolving Credit Facility [Member]",
        "terseLabel": "Revolving Credit Facility"
       }
      }
     },
     "localname": "RevolvingCreditFacilityMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SalesRevenueProductLineMember": {
     "auth_ref": [
      "r145"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Revenue from specified product or service, when it serves as benchmark in concentration of risk calculation. Includes, but is not limited to, revenue from contract with customer and other sources.",
        "label": "Revenue, Product and Service Benchmark [Member]",
        "terseLabel": "Revenue, Product and Service Benchmark"
       }
      }
     },
     "localname": "SalesRevenueProductLineMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ScheduleOfAccruedLiabilitiesTableTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the components of accrued liabilities.",
        "label": "Schedule of Accrued Liabilities [Table Text Block]",
        "terseLabel": "Schedule of Other Accrued Liabilities"
       }
      }
     },
     "localname": "ScheduleOfAccruedLiabilitiesTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule for securities (including those issuable pursuant to contingent stock agreements) that could potentially dilute basic earnings per share (EPS) in the future that were not included in the computation of diluted EPS because to do so would increase EPS amounts or decrease loss per share amounts for the period presented, by Antidilutive Securities.",
        "label": "Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share [Table]",
        "terseLabel": "Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share [Table]"
       }
      }
     },
     "localname": "ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of securities (including those issuable pursuant to contingent stock agreements) that could potentially dilute basic earnings per share (EPS) in the future that were not included in the computation of diluted EPS because to do so would increase EPS amounts or decrease loss per share amounts for the period presented, by antidilutive securities.",
        "label": "Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share [Table Text Block]",
        "terseLabel": "Shares Not Included in Computation of Diluted Net (Income) Loss Per Share"
       }
      }
     },
     "localname": "ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfCashAndCashEquivalentsTable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule of cash and cash equivalent balances. This table excludes restricted cash balances.",
        "label": "Schedule of Cash and Cash Equivalents [Table]",
        "terseLabel": "Schedule of Cash and Cash Equivalents [Table]"
       }
      }
     },
     "localname": "ScheduleOfCashAndCashEquivalentsTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfCashAndCashEquivalentsTableTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the components of cash and cash equivalents.",
        "label": "Schedule of Cash and Cash Equivalents [Table Text Block]",
        "terseLabel": "Schedule of Cash and Cash Equivalents"
       }
      }
     },
     "localname": "ScheduleOfCashAndCashEquivalentsTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfCollaborativeArrangementsAndNoncollaborativeArrangementTransactionsTable": {
     "auth_ref": [
      "r390"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about collaborative arrangement and arrangement other than collaborative applicable to revenue-generating activity or operations.",
        "label": "Collaborative Arrangement and Arrangement Other than Collaborative [Table]",
        "terseLabel": "Collaborative Arrangement and Arrangement Other than Collaborative [Table]"
       }
      }
     },
     "localname": "ScheduleOfCollaborativeArrangementsAndNoncollaborativeArrangementTransactionsTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfEarningsPerShareBasicAndDilutedTableTextBlock": {
     "auth_ref": [
      "r127"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of an entity's basic and diluted earnings per share calculations, including a reconciliation of numerators and denominators of the basic and diluted per-share computations for income from continuing operations.",
        "label": "Schedule of Earnings Per Share, Basic and Diluted [Table Text Block]",
        "terseLabel": "Schedule of Income (Loss) Per Share"
       }
      }
     },
     "localname": "ScheduleOfEarningsPerShareBasicAndDilutedTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable": {
     "auth_ref": [
      "r364",
      "r372",
      "r380"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about amount recognized for award under share-based payment arrangement. Includes, but is not limited to, amount expensed in statement of income or comprehensive income, amount capitalized in statement of financial position, and corresponding reporting line item in financial statements.",
        "label": "Share-based Payment Arrangement, Expensed and Capitalized, Amount [Table]",
        "terseLabel": "Share-based Payment Arrangement, Expensed and Capitalized, Amount [Table]"
       }
      }
     },
     "localname": "ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock": {
     "auth_ref": [
      "r364",
      "r372",
      "r380"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of allocation of amount expensed and capitalized for award under share-based payment arrangement to statement of income or comprehensive income and statement of financial position. Includes, but is not limited to, corresponding line item in financial statement.",
        "label": "Share-based Payment Arrangement, Expensed and Capitalized, Amount [Table Text Block]",
        "verboseLabel": "Schedule of Stock-based Compensation Expense"
       }
      }
     },
     "localname": "ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock": {
     "auth_ref": [
      "r193"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the names of foreign countries in which material long-lived assets other than financial instruments, long-term customer relationships of a financial institution, mortgage and other servicing rights, deferred policy acquisition costs, and deferred tax assets are located, and amount of such long-lived assets located in that country or foreign geographic area.",
        "label": "Schedule of Disclosure on Geographic Areas, Long-Lived Assets in Individual Foreign Countries by Country [Table Text Block]",
        "verboseLabel": "Schedule of Long-Lived Assets by Geographical Area"
       }
      }
     },
     "localname": "ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfFinancingReceivableAllowanceForCreditLossesTable": {
     "auth_ref": [
      "r222",
      "r548"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about allowance for credit loss on financing receivable.",
        "label": "Financing Receivable, Allowance for Credit Loss [Table]",
        "terseLabel": "Financing Receivable, Allowance for Credit Loss [Table]"
       }
      }
     },
     "localname": "ScheduleOfFinancingReceivableAllowanceForCreditLossesTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock": {
     "auth_ref": [
      "r240"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of goodwill and intangible assets, which may be broken down by segment or major class.",
        "label": "Schedule of Intangible Assets and Goodwill [Table Text Block]",
        "terseLabel": "Schedule of Goodwill"
       }
      }
     },
     "localname": "ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfInventoryCurrentTableTextBlock": {
     "auth_ref": [
      "r10",
      "r28",
      "r29",
      "r30"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the carrying amount as of the balance sheet date of merchandise, goods, commodities, or supplies held for future sale or to be used in manufacturing, servicing or production process.",
        "label": "Schedule of Inventory, Current [Table Text Block]",
        "verboseLabel": "Schedule of Inventory Components"
       }
      }
     },
     "localname": "ScheduleOfInventoryCurrentTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfPropertyPlantAndEquipmentTable": {
     "auth_ref": [
      "r35",
      "r244"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about physical assets used in the normal conduct of business and not intended for resale. Includes, but is not limited to, balances by class of assets, depreciation and depletion expense and method used, including composite depreciation, and accumulated deprecation.",
        "label": "Property, Plant and Equipment [Table]",
        "terseLabel": "Schedule of Property, Plant and Equipment [Table]"
       }
      }
     },
     "localname": "ScheduleOfPropertyPlantAndEquipmentTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable": {
     "auth_ref": [
      "r438",
      "r440"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule of quantitative and qualitative information pertaining to related party transactions. Examples of related party transactions include transactions between (a) a parent company and its subsidiary; (b) subsidiaries of a common parent; (c) and entity and its principal owners; and (d) affiliates.",
        "label": "Schedule of Related Party Transactions, by Related Party [Table]",
        "terseLabel": "Schedule of Related Party Transactions, by Related Party [Table]"
       }
      }
     },
     "localname": "ScheduleOfRelatedPartyTransactionsByRelatedPartyTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable": {
     "auth_ref": [
      "r166",
      "r169",
      "r181",
      "r240"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "A table disclosing the profit or loss and total assets for each reportable segment of the entity. An entity discloses certain information on each reportable segment if the amounts (a) are included in the measure of segment profit or loss reviewed by the chief operating decision maker or (b) are otherwise regularly provided to the chief operating decision maker, even if not included in that measure of segment profit or loss.",
        "label": "Schedule of Segment Reporting Information, by Segment [Table]",
        "terseLabel": "Schedule of Segment Reporting Information, by Segment [Table]"
       }
      }
     },
     "localname": "ScheduleOfSegmentReportingInformationBySegmentTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfSegmentReportingInformationBySegmentTextBlock": {
     "auth_ref": [
      "r166",
      "r169",
      "r181",
      "r240"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the profit or loss and total assets for each reportable segment. An entity discloses certain information on each reportable segment if the amounts (a) are included in the measure of segment profit or loss reviewed by the chief operating decision maker or (b) are otherwise regularly provided to the chief operating decision maker, even if not included in that measure of segment profit or loss.",
        "label": "Schedule of Segment Reporting Information, by Segment [Table Text Block]",
        "terseLabel": "Schedule of Segment Reporting"
       }
      }
     },
     "localname": "ScheduleOfSegmentReportingInformationBySegmentTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable": {
     "auth_ref": [
      "r365",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of information about share-based payment arrangement.",
        "label": "Schedule of Share-based Compensation Arrangements by Share-based Payment Award [Table]",
        "terseLabel": "Schedule of Share-based Compensation Arrangements by Share-based Payment Award [Table]"
       }
      }
     },
     "localname": "ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfSharebasedCompensationRestrictedStockAndRestrictedStockUnitsActivityTableTextBlock": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of the number and weighted-average grant date fair value for restricted stock and restricted stock units that were outstanding at the beginning and end of the year, and the number of restricted stock and restricted stock units that were granted, vested, or forfeited during the year.",
        "label": "Share-based Payment Arrangement, Restricted Stock and Restricted Stock Unit, Activity [Table Text Block]",
        "terseLabel": "Schedule of Stock-based Compensation Expense by Security Types"
       }
      }
     },
     "localname": "ScheduleOfSharebasedCompensationRestrictedStockAndRestrictedStockUnitsActivityTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SchedulesOfConcentrationOfRiskByRiskFactorTextBlock": {
     "auth_ref": [
      "r143",
      "r146",
      "r147",
      "r148",
      "r404",
      "r406"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of the nature of a concentration, a benchmark to which it is compared, and the percentage that the risk is to the benchmark.",
        "label": "Schedules of Concentration of Risk, by Risk Factor [Table Text Block]",
        "terseLabel": "Schedule of Concentration Risk"
       }
      }
     },
     "localname": "SchedulesOfConcentrationOfRiskByRiskFactorTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SecurityDeposit": {
     "auth_ref": [
      "r52"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of an asset, typically cash, provided to a counterparty to provide certain assurance of performance by the entity pursuant to the terms of a written or oral agreement, such as a lease.",
        "label": "Security Deposit",
        "terseLabel": "Security deposit"
       }
      }
     },
     "localname": "SecurityDeposit",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesNarrativeDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SecurityOwnedNotReadilyMarketableAxis": {
     "auth_ref": [
      "r461"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by name of not readily marketable security.",
        "label": "Security Owned Not Readily Marketable [Axis]",
        "terseLabel": "Security Owned Not Readily Marketable [Axis]"
       }
      }
     },
     "localname": "SecurityOwnedNotReadilyMarketableAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SecurityOwnedNotReadilyMarketableNameDomain": {
     "auth_ref": [
      "r461"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Name of the security category or actual security title.",
        "label": "Security Owned Not Readily Marketable, Name [Domain]",
        "terseLabel": "Security Owned Not Readily Marketable, Name [Domain]"
       }
      }
     },
     "localname": "SecurityOwnedNotReadilyMarketableNameDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SegmentDomain": {
     "auth_ref": [
      "r153",
      "r157",
      "r158",
      "r159",
      "r160",
      "r161",
      "r162",
      "r163",
      "r164",
      "r165",
      "r166",
      "r167",
      "r168",
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r183",
      "r184",
      "r185",
      "r186",
      "r188",
      "r195",
      "r249",
      "r250",
      "r494"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Components of an entity that engage in business activities from which they may earn revenue and incur expenses, including transactions with other components of the same entity.",
        "label": "Segments [Domain]",
        "terseLabel": "Segments [Domain]"
       }
      }
     },
     "localname": "SegmentDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SegmentReportingAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment Reporting [Abstract]",
        "terseLabel": "Segment Reporting [Abstract]"
       }
      }
     },
     "localname": "SegmentReportingAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_SegmentReportingDisclosureTextBlock": {
     "auth_ref": [
      "r153",
      "r155",
      "r156",
      "r166",
      "r170",
      "r182",
      "r186",
      "r187",
      "r188",
      "r189",
      "r191",
      "r194",
      "r195",
      "r196"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for reporting segments including data and tables. Reportable segments include those that meet any of the following quantitative thresholds a) it's reported revenue, including sales to external customers and intersegment sales or transfers is 10 percent or more of the combined revenue, internal and external, of all operating segments b) the absolute amount of its reported profit or loss is 10 percent or more of the greater, in absolute amount of 1) the combined reported profit of all operating segments that did not report a loss or 2) the combined reported loss of all operating segments that did report a loss c) its assets are 10 percent or more of the combined assets of all operating segments.",
        "label": "Segment Reporting Disclosure [Text Block]",
        "verboseLabel": "Segment, Geographical and Other Revenue Information"
       }
      }
     },
     "localname": "SegmentReportingDisclosureTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformation"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SegmentReportingInformationLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Segment Reporting Information [Line Items]",
        "terseLabel": "Segment Reporting Information [Line Items]"
       }
      }
     },
     "localname": "SegmentReportingInformationLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SegmentReportingPolicyPolicyTextBlock": {
     "auth_ref": [
      "r171",
      "r172",
      "r173",
      "r174",
      "r175",
      "r176",
      "r192"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of accounting policy for segment reporting.",
        "label": "Segment Reporting, Policy [Policy Text Block]",
        "terseLabel": "Segment Information"
       }
      }
     },
     "localname": "SegmentReportingPolicyPolicyTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SellingGeneralAndAdministrativeExpense": {
     "auth_ref": [
      "r69"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_CostsAndExpenses",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The aggregate total costs related to selling a firm's product and services, as well as all other general and administrative expenses. Direct selling expenses (for example, credit, warranty, and advertising) are expenses that can be directly linked to the sale of specific products. Indirect selling expenses are expenses that cannot be directly linked to the sale of specific products, for example telephone expenses, Internet, and postal charges. General and administrative expenses include salaries of non-sales personnel, rent, utilities, communication, etc.",
        "label": "Selling, General and Administrative Expense",
        "terseLabel": "Selling, general and administrative"
       }
      }
     },
     "localname": "SellingGeneralAndAdministrativeExpense",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SellingGeneralAndAdministrativeExpensesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Primary financial statement caption encompassing selling, general and administrative expense.",
        "label": "Selling, General and Administrative Expenses [Member]",
        "verboseLabel": "Selling, general and administrative"
       }
      }
     },
     "localname": "SellingGeneralAndAdministrativeExpensesMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SeriesAPreferredStockMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Outstanding nonredeemable series A preferred stock or outstanding series A preferred stock. Classified within stockholders' equity if nonredeemable or redeemable solely at the option of the issuer. Classified within temporary equity if redemption is outside the control of the issuer.",
        "label": "Series A Preferred Stock [Member]",
        "terseLabel": "Series A Preferred Stock"
       }
      }
     },
     "localname": "SeriesAPreferredStockMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SeriesBPreferredStockMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Outstanding nonredeemable series B preferred stock or outstanding series B preferred stock. Classified within stockholders' equity if nonredeemable or redeemable solely at the option of the issuer. Classified within temporary equity if redemption is outside the control of the issuer.",
        "label": "Series B Preferred Stock [Member]",
        "terseLabel": "Series B Preferred Stock"
       }
      }
     },
     "localname": "SeriesBPreferredStockMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedCompensation": {
     "auth_ref": [
      "r86"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited": {
       "order": 4.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of noncash expense for share-based payment arrangement.",
        "label": "Share-based Payment Arrangement, Noncash Expense",
        "verboseLabel": "Stock-based compensation"
       }
      }
     },
     "localname": "ShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1": {
     "auth_ref": [
      "r366"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Period over which grantee's right to exercise award under share-based payment arrangement is no longer contingent on satisfaction of service or performance condition, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents reported fact of one year, five months, and thirteen days. Includes, but is not limited to, combination of market, performance or service condition.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Award Vesting Period",
        "terseLabel": "Award vesting period"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award [Line Items]",
        "terseLabel": "Share-based Compensation Arrangement by Share-based Payment Award [Line Items]"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized": {
     "auth_ref": [
      "r368"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of shares authorized for issuance under share-based payment arrangement.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Number of Shares Authorized",
        "terseLabel": "Number of shares authorized (in shares)"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant": {
     "auth_ref": [
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The difference between the maximum number of shares (or other type of equity) authorized for issuance under the plan (including the effects of amendments and adjustments), and the sum of: 1) the number of shares (or other type of equity) already issued upon exercise of options or other equity-based awards under the plan; and 2) shares (or other type of equity) reserved for issuance on granting of outstanding awards, net of cancellations and forfeitures, if applicable.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Number of Shares Available for Grant",
        "terseLabel": "Number of shares available for grant (in shares)"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain": {
     "auth_ref": [
      "r363",
      "r369"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Award under share-based payment arrangement.",
        "label": "Award Type [Domain]",
        "terseLabel": "Award Type [Domain]"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardOptionsExercisesInPeriodWeightedAverageExercisePrice": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Weighted average price at which option holders acquired shares when converting their stock options into shares.",
        "label": "Share-based Compensation Arrangements by Share-based Payment Award, Options, Exercises in Period, Weighted Average Exercise Price",
        "terseLabel": "Weighted average exercise price of stock options exercised (usd per share)"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementsByShareBasedPaymentAwardOptionsExercisesInPeriodWeightedAverageExercisePrice",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_ShareBasedCompensationAwardTrancheOneMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "First portion of award under share-based payment arrangement differentiated by vesting feature, including, but not limited to, performance measure or service period.",
        "label": "Share-based Payment Arrangement, Tranche One [Member]",
        "terseLabel": "Tranche One"
       }
      }
     },
     "localname": "ShareBasedCompensationAwardTrancheOneMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedCompensationAwardTrancheTwoMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Second portion of award under share-based payment arrangement differentiated by vesting feature, including, but not limited to, performance measure or service period.",
        "label": "Share-based Payment Arrangement, Tranche Two [Member]",
        "terseLabel": "Tranche Two"
       }
      }
     },
     "localname": "ShareBasedCompensationAwardTrancheTwoMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedPaymentArrangementEmployeeMember": {
     "auth_ref": [
      "r362",
      "r371"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Recipient, of award granted under share-based payment arrangement, over whom grantor exercises or has right to exercise sufficient control to establish employer-employee relationship based on law of pertinent jurisdiction. Includes, but is not limited to, nonemployee director treated as employee when acting as member of board of directors, if elected by grantor's shareholders or appointed to board position to be filled by shareholder election when existing term expires.",
        "label": "Share-based Payment Arrangement, Employee [Member]",
        "terseLabel": "Employee"
       }
      }
     },
     "localname": "ShareBasedPaymentArrangementEmployeeMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedPaymentArrangementNonemployeeMember": {
     "auth_ref": [
      "r360",
      "r371"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Recipient, of award granted under share-based payment arrangement, over whom grantor does not exercise nor has right to exercise sufficient control to establish employer-employee relationship based on law of pertinent jurisdiction. Excludes nonemployee director treated as employee when acting as member of board of directors, if elected by grantor's shareholders or appointed to board position to be filled by shareholder election when existing term expires.",
        "label": "Share-based Payment Arrangement, Nonemployee [Member]",
        "terseLabel": "Nonemployee"
       }
      }
     },
     "localname": "ShareBasedPaymentArrangementNonemployeeMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage": {
     "auth_ref": [
      "r366"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Percentage of vesting of award under share-based payment arrangement.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Award Vesting Rights, Percentage",
        "terseLabel": "Award vesting rights percentage"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod": {
     "auth_ref": [
      "r367"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Period from grant date that an equity-based award expires, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents the reported fact of one year, five months, and thirteen days.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Expiration Period",
        "terseLabel": "Expiration period"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementBySharebasedPaymentAwardExpirationPeriod",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_SharebasedCompensationArrangementBySharebasedPaymentAwardPurchasePriceOfCommonStockPercent": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Purchase price of common stock expressed as a percentage of its fair value.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Purchase Price of Common Stock, Percent",
        "terseLabel": "Purchase price of common stock"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementBySharebasedPaymentAwardPurchasePriceOfCommonStockPercent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_SharesOutstanding": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of shares issued which are neither cancelled nor held in the treasury.",
        "label": "Shares, Outstanding",
        "periodEndLabel": "Balance at end of period (in shares)",
        "periodStartLabel": "Balance at beginning of period (in shares)"
       }
      }
     },
     "localname": "SharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_SharesPaidForTaxWithholdingForShareBasedCompensation": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of shares used to settle grantee's tax withholding obligation for award under share-based payment arrangement.",
        "label": "Share-based Payment Arrangement, Shares Withheld for Tax Withholding Obligation",
        "negatedTerseLabel": "Taxes paid related to net shares settlement of equity awards (in shares)"
       }
      }
     },
     "localname": "SharesPaidForTaxWithholdingForShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShortTermLeaseCost": {
     "auth_ref": [
      "r424",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 3.0,
       "parentTag": "us-gaap_LeaseCost",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of short-term lease cost, excluding expense for lease with term of one month or less.",
        "label": "Short-term Lease, Cost",
        "terseLabel": "Short-term lease costs"
       }
      }
     },
     "localname": "ShortTermLeaseCost",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SignificantAccountingPoliciesTextBlock": {
     "auth_ref": [
      "r95",
      "r104"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for all significant accounting policies of the reporting entity.",
        "label": "Significant Accounting Policies [Text Block]",
        "verboseLabel": "Basis of Presentation and Summary of Significant Accounting Policies"
       }
      }
     },
     "localname": "SignificantAccountingPoliciesTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SignificantSupplyCommitmentRemainingMinimumAmountCommitted": {
     "auth_ref": [
      "r44",
      "r470",
      "r487"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The floor amount as of the balance sheet date that the entity must expend to satisfy the terms of disclosed arrangements (excluding long-term commitments) in which the entity must commit resources to supply goods or services to one or more customers.",
        "label": "Supply Commitment, Remaining Minimum Amount Committed",
        "terseLabel": "Future Minimum Payment"
       }
      }
     },
     "localname": "SignificantSupplyCommitmentRemainingMinimumAmountCommitted",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_StatementBusinessSegmentsAxis": {
     "auth_ref": [
      "r1",
      "r153",
      "r157",
      "r158",
      "r159",
      "r160",
      "r161",
      "r162",
      "r163",
      "r164",
      "r165",
      "r166",
      "r167",
      "r168",
      "r177",
      "r178",
      "r179",
      "r180",
      "r182",
      "r183",
      "r184",
      "r185",
      "r186",
      "r188",
      "r195",
      "r240",
      "r246",
      "r249",
      "r250",
      "r494"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by business segments.",
        "label": "Segments [Axis]",
        "terseLabel": "Segments [Axis]"
       }
      }
     },
     "localname": "StatementBusinessSegmentsAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementClassOfStockAxis": {
     "auth_ref": [
      "r17",
      "r18",
      "r19",
      "r96",
      "r98",
      "r121",
      "r122",
      "r123",
      "r125",
      "r127",
      "r135",
      "r136",
      "r137",
      "r217",
      "r266",
      "r271",
      "r272",
      "r273",
      "r279",
      "r280",
      "r298",
      "r299",
      "r303",
      "r307",
      "r313",
      "r407",
      "r533"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by the different classes of stock of the entity.",
        "label": "Class of Stock [Axis]",
        "terseLabel": "Class of Stock [Axis]"
       }
      }
     },
     "localname": "StatementClassOfStockAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesNarrativeDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementEquityComponentsAxis": {
     "auth_ref": [
      "r0",
      "r46",
      "r59",
      "r60",
      "r61",
      "r105",
      "r106",
      "r107",
      "r109",
      "r115",
      "r117",
      "r134",
      "r218",
      "r313",
      "r314",
      "r376",
      "r377",
      "r378",
      "r386",
      "r387",
      "r396",
      "r409",
      "r410",
      "r411",
      "r412",
      "r413",
      "r414",
      "r500",
      "r501",
      "r502",
      "r556"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by component of equity.",
        "label": "Equity Components [Axis]",
        "terseLabel": "Equity Components [Axis]"
       }
      }
     },
     "localname": "StatementEquityComponentsAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Statement [Line Items]",
        "terseLabel": "Statement [Line Items]"
       }
      }
     },
     "localname": "StatementLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementOfCashFlowsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of Cash Flows [Abstract]",
        "terseLabel": "Statement of Cash Flows [Abstract]"
       }
      }
     },
     "localname": "StatementOfCashFlowsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementOfFinancialPositionAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of Financial Position [Abstract]",
        "terseLabel": "Statement of Financial Position [Abstract]"
       }
      }
     },
     "localname": "StatementOfFinancialPositionAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementOfStockholdersEquityAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement of Stockholders' Equity [Abstract]",
        "terseLabel": "Statement of Stockholders' Equity [Abstract]"
       }
      }
     },
     "localname": "StatementOfStockholdersEquityAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementTable": {
     "auth_ref": [
      "r105",
      "r106",
      "r107",
      "r134",
      "r459"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule reflecting a Statement of Income, Statement of Cash Flows, Statement of Financial Position, Statement of Shareholders' Equity and Other Comprehensive Income, or other statement as needed.",
        "label": "Statement [Table]",
        "terseLabel": "Statement [Table]"
       }
      }
     },
     "localname": "StatementTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StockCompensationPlanMember": {
     "auth_ref": [
      "r128"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Share-based payment arrangement in which award of equity shares are granted. Arrangement includes, but is not limited to, grantor incurring liability for product and service based on price of its shares.",
        "label": "Share-based Payment Arrangement [Member]",
        "terseLabel": "Shares issuable under the Equity Incentive Plan"
       }
      }
     },
     "localname": "StockCompensationPlanMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareSharesNotIncludedinComputationofDilutedNetIncomeLossPerShareDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_StockIssuedDuringPeriodSharesNewIssues": {
     "auth_ref": [
      "r18",
      "r19",
      "r313",
      "r314"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of new stock issued during the period.",
        "label": "Stock Issued During Period, Shares, New Issues",
        "verboseLabel": "Shares issued (in shares)"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodSharesNewIssues",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_StockIssuedDuringPeriodSharesOther": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of shares of stock issued attributable to transactions classified as other.",
        "label": "Stock Issued During Period, Shares, Other",
        "terseLabel": "Release of stock awards (in shares)"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodSharesOther",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_StockIssuedDuringPeriodSharesStockOptionsExercised": {
     "auth_ref": [
      "r18",
      "r19",
      "r313",
      "r314",
      "r370"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of share options (or share units) exercised during the current period.",
        "label": "Share-based Compensation Arrangement by Share-based Payment Award, Options, Exercises in Period",
        "terseLabel": "Stock options exercised (in shares)",
        "verboseLabel": "Exercise of stock options (in shares)"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodSharesStockOptionsExercised",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised": {
     "auth_ref": [
      "r46",
      "r313",
      "r314"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Value of stock issued as a result of the exercise of stock options.",
        "label": "Stock Issued During Period, Value, Stock Options Exercised",
        "verboseLabel": "Exercise of stock options"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodValueStockOptionsExercised",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_StockholdersEquity": {
     "auth_ref": [
      "r19",
      "r24",
      "r25",
      "r98",
      "r204",
      "r217",
      "r407",
      "r445"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 2.0,
       "parentTag": "us-gaap_LiabilitiesAndStockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Total of all stockholders' equity (deficit) items, net of receivables from officers, directors, owners, and affiliates of the entity which are attributable to the parent. The amount of the economic entity's stockholders' equity attributable to the parent excludes the amount of stockholders' equity which is allocable to that ownership interest in subsidiary equity which is not attributable to the parent (noncontrolling interest, minority interest). This excludes temporary equity and is sometimes called permanent equity.",
        "label": "Stockholders' Equity Attributable to Parent",
        "periodEndLabel": "Balance at end of period",
        "periodStartLabel": "Balance at beginning of period",
        "totalLabel": "Total stockholders' equity"
       }
      }
     },
     "localname": "StockholdersEquity",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquityUnaudited"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_StockholdersEquityAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Stockholders' Equity Attributable to Parent [Abstract]",
        "verboseLabel": "Stockholders' equity:"
       }
      }
     },
     "localname": "StockholdersEquityAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StockholdersEquityNoteDisclosureTextBlock": {
     "auth_ref": [
      "r97",
      "r299",
      "r302",
      "r303",
      "r304",
      "r305",
      "r306",
      "r307",
      "r308",
      "r309",
      "r310",
      "r311",
      "r312",
      "r314",
      "r315"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for shareholders' equity comprised of portions attributable to the parent entity and noncontrolling interest, including other comprehensive income. Includes, but is not limited to, balances of common stock, preferred stock, additional paid-in capital, other capital and retained earnings, accumulated balance for each classification of other comprehensive income and amount of comprehensive income.",
        "label": "Stockholders' Equity Note Disclosure [Text Block]",
        "terseLabel": "Capital Stock"
       }
      }
     },
     "localname": "StockholdersEquityNoteDisclosureTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStock"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SubleaseIncome": {
     "auth_ref": [
      "r426",
      "r432"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 4.0,
       "parentTag": "us-gaap_LeaseCost",
       "weight": -1.0
      }
     },
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of sublease income excluding finance and operating lease expense.",
        "label": "Sublease Income",
        "negatedLabel": "Sublease income"
       }
      }
     },
     "localname": "SubleaseIncome",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SubsidiaryOrEquityMethodInvesteeSaleOfStockBySubsidiaryOrEquityInvesteeTable": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Different names of stock transactions and the different attributes of each transaction.",
        "label": "Subsidiary or Equity Method Investee, Sale of Stock by Subsidiary or Equity Investee [Table]",
        "terseLabel": "Subsidiary or Equity Method Investee, Sale of Stock by Subsidiary or Equity Investee [Table]"
       }
      }
     },
     "localname": "SubsidiaryOrEquityMethodInvesteeSaleOfStockBySubsidiaryOrEquityInvesteeTable",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SubsidiarySaleOfStockLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "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.",
        "label": "Subsidiary, Sale of Stock [Line Items]",
        "terseLabel": "Subsidiary, Sale of Stock [Line Items]"
       }
      }
     },
     "localname": "SubsidiarySaleOfStockLineItems",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SupplementalCashFlowInformationAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Supplemental Cash Flow Information [Abstract]",
        "terseLabel": "Supplemental disclosure of cash flow information:"
       }
      }
     },
     "localname": "SupplementalCashFlowInformationAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SupplyCommitmentArrangementMember": {
     "auth_ref": [
      "r16",
      "r466",
      "r481"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This item is intended to be populated, by the entity, with Members identifying each supply commitment about which information required or determined to be disclosed is being provided. If only one such commitment exists, this item may be used to capture such information; if multiple commitments exist, this item is the dimensional default, which will aggregate such information, as appropriate.",
        "label": "Supply Commitment Arrangement [Domain]",
        "terseLabel": "Supply Commitment Arrangement [Domain]"
       }
      }
     },
     "localname": "SupplyCommitmentArrangementMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SupplyCommitmentAxis": {
     "auth_ref": [
      "r16",
      "r466",
      "r481"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by arrangements in which the entity has committed resources to supply goods or services to a customer.",
        "label": "Supply Commitment [Axis]",
        "terseLabel": "Supply Commitment [Axis]"
       }
      }
     },
     "localname": "SupplyCommitmentAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SupplyCommitmentMember": {
     "auth_ref": [
      "r16",
      "r466",
      "r481"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Supply arrangement in which the entity has agreed to commit resources to supply goods or services to a customer. Excludes long-term commitments.",
        "label": "Supply Commitment [Member]",
        "terseLabel": "Supply Commitment"
       }
      }
     },
     "localname": "SupplyCommitmentMember",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SupplyCommitmentTableTextBlock": {
     "auth_ref": [
      "r16"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of arrangements in which the entity has committed resources to supply goods or services to a customer. May include identification of the goods or services to be furnished, identity of the purchasing party, pricing, effects on pricing for failing to deliver the [minimum] quantities required to be furnished, cancellation rights, and termination provisions.",
        "label": "Supply Commitment [Table Text Block]",
        "terseLabel": "Schedule of Supply and Service Commitments"
       }
      }
     },
     "localname": "SupplyCommitmentTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_UnbilledReceivablesCurrent": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited": {
       "order": 3.0,
       "parentTag": "us-gaap_NotesReceivableGross",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount received for services rendered and products shipped, but not yet billed, for non-contractual agreements due within one year or the normal operating cycle, if longer.",
        "label": "Unbilled Receivables, Current",
        "terseLabel": "Unbilled receivables"
       }
      }
     },
     "localname": "UnbilledReceivablesCurrent",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsUnaudited",
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_UseOfEstimates": {
     "auth_ref": [
      "r139",
      "r140",
      "r141",
      "r142",
      "r149",
      "r150",
      "r151"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Disclosure of accounting policy for the use of estimates in the preparation of financial statements in conformity with generally accepted accounting principles.",
        "label": "Use of Estimates, Policy [Policy Text Block]",
        "terseLabel": "Use of Estimates"
       }
      }
     },
     "localname": "UseOfEstimates",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_VariableLeaseCost": {
     "auth_ref": [
      "r425",
      "r432"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of variable lease cost, excluded from lease liability, recognized when obligation for payment is incurred for finance and operating leases.",
        "label": "Variable Lease, Cost",
        "terseLabel": "Variable lease cost"
       }
      }
     },
     "localname": "VariableLeaseCost",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_VestingAxis": {
     "auth_ref": [
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by vesting schedule of award under share-based payment arrangement.",
        "label": "Vesting [Axis]",
        "terseLabel": "Vesting [Axis]"
       }
      }
     },
     "localname": "VestingAxis",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_VestingDomain": {
     "auth_ref": [
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Vesting schedule of award under share-based payment arrangement.",
        "label": "Vesting [Domain]",
        "terseLabel": "Vesting [Domain]"
       }
      }
     },
     "localname": "VestingDomain",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails",
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_WeightedAverageNumberDilutedSharesOutstandingAdjustment": {
     "auth_ref": [
      "r127"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The sum of dilutive potential common shares or units used in the calculation of the diluted per-share or per-unit computation.",
        "label": "Weighted Average Number Diluted Shares Outstanding Adjustment",
        "terseLabel": "Effect of dilutive shares (shares)"
       }
      }
     },
     "localname": "WeightedAverageNumberDilutedSharesOutstandingAdjustment",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding": {
     "auth_ref": [
      "r120",
      "r127"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The average number of shares or units issued and outstanding that are used in calculating diluted EPS or earnings per unit (EPU), determined based on the timing of issuance of shares or units in the period.",
        "label": "Weighted Average Number of Shares Outstanding, Diluted",
        "terseLabel": "Weighted average common stock shares used in computing net income (loss) per share, diluted (in shares)"
       }
      }
     },
     "localname": "WeightedAverageNumberOfDilutedSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_WeightedAverageNumberOfSharesOutstandingBasic": {
     "auth_ref": [
      "r119",
      "r127"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Number of [basic] shares or units, after adjustment for contingently issuable shares or units and other shares or units not deemed outstanding, determined by relating the portion of time within a reporting period that common shares or units have been outstanding to the total time in that period.",
        "label": "Weighted Average Number of Shares Outstanding, Basic",
        "terseLabel": "Weighted average common stock shares used in computing net income (loss) per share, basic (in shares)"
       }
      }
     },
     "localname": "WeightedAverageNumberOfSharesOutstandingBasic",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperationsUnaudited",
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_WeightedAverageNumberOfSharesOutstandingDilutedDisclosureItemsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Weighted Average Number of Shares Outstanding Reconciliation [Abstract]",
        "terseLabel": "Denominator:"
       }
      }
     },
     "localname": "WeightedAverageNumberOfSharesOutstandingDilutedDisclosureItemsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2021-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetIncomelossperShareEarningsPerShareDetails"
     ],
     "xbrltype": "stringItemType"
    }
   },
   "unitCount": 9
  }
 },
 "std_ref": {
  "r0": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "105",
   "URI": "http://asc.fasb.org/extlink&oid=124434974&loc=SL124442142-165695"
  },
  "r1": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)",
   "Topic": "205",
   "URI": "http://asc.fasb.org/extlink&oid=109222650&loc=d3e1361-107760"
  },
  "r10": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=6361739&loc=d3e7789-107766"
  },
  "r100": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(k)(1))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r101": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(m)(1)(iii))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r102": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(m)(2)(ii))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r103": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.12-04(a))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e24072-122690"
  },
  "r104": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "235",
   "URI": "http://asc.fasb.org/topic&trid=2122369"
  },
  "r105": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "23",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124436220&loc=d3e21914-107793"
  },
  "r106": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "24",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124436220&loc=d3e21930-107793"
  },
  "r107": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124436220&loc=d3e21711-107793"
  },
  "r108": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(2)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22499-107794"
  },
  "r109": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(3)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22499-107794"
  },
  "r11": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(1))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r110": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22694-107794"
  },
  "r111": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22694-107794"
  },
  "r112": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22583-107794"
  },
  "r113": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22595-107794"
  },
  "r114": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22644-107794"
  },
  "r115": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22644-107794"
  },
  "r116": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22658-107794"
  },
  "r117": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=124431687&loc=d3e22663-107794"
  },
  "r118": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB Topic 11.M.Q2)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=122038215&loc=d3e31137-122693"
  },
  "r119": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e1448-109256"
  },
  "r12": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(13))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r120": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "16",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e1505-109256"
  },
  "r121": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e1252-109256"
  },
  "r122": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e1278-109256"
  },
  "r123": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "55",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e2626-109256"
  },
  "r124": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "60B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=SL5780133-109256"
  },
  "r125": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "60B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=SL5780133-109256"
  },
  "r126": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125511455&loc=d3e1337-109256"
  },
  "r127": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=124432515&loc=d3e3550-109257"
  },
  "r128": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=124432515&loc=d3e3550-109257"
  },
  "r129": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=124432515&loc=d3e3630-109257"
  },
  "r13": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(14))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r130": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=109243012&loc=SL65017193-207537"
  },
  "r131": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125512782&loc=d3e3842-109258"
  },
  "r132": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "52",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=125512782&loc=d3e4984-109258"
  },
  "r133": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "260",
   "URI": "http://asc.fasb.org/topic&trid=2144383"
  },
  "r134": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=125520817&loc=d3e70191-108054"
  },
  "r135": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=125520817&loc=d3e70229-108054"
  },
  "r136": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=6373374&loc=d3e70434-108055"
  },
  "r137": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=6373374&loc=d3e70478-108055"
  },
  "r138": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e5967-108592"
  },
  "r139": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e5967-108592"
  },
  "r14": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(17))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r140": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e5967-108592"
  },
  "r141": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6161-108592"
  },
  "r142": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6191-108592"
  },
  "r143": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "16",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6327-108592"
  },
  "r144": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6351-108592"
  },
  "r145": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6351-108592"
  },
  "r146": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6351-108592"
  },
  "r147": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6404-108592"
  },
  "r148": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6442-108592"
  },
  "r149": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6061-108592"
  },
  "r15": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(22))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r150": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6132-108592"
  },
  "r151": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "275",
   "URI": "http://asc.fasb.org/extlink&oid=99393423&loc=d3e6143-108592"
  },
  "r152": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "275",
   "URI": "http://asc.fasb.org/topic&trid=2134479"
  },
  "r153": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8657-108599"
  },
  "r154": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8672-108599"
  },
  "r155": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8721-108599"
  },
  "r156": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8721-108599"
  },
  "r157": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r158": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r159": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r16": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(25))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r160": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r161": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r162": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r163": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r164": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(h)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r165": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(j)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r166": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8736-108599"
  },
  "r167": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8813-108599"
  },
  "r168": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8813-108599"
  },
  "r169": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8813-108599"
  },
  "r17": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(27))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r170": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "26",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8844-108599"
  },
  "r171": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r172": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r173": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r174": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r175": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r176": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8864-108599"
  },
  "r177": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8906-108599"
  },
  "r178": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8906-108599"
  },
  "r179": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8906-108599"
  },
  "r18": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(28))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r180": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8906-108599"
  },
  "r181": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8906-108599"
  },
  "r182": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "31",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8924-108599"
  },
  "r183": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r184": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r185": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r186": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r187": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r188": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8933-108599"
  },
  "r189": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "34",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8981-108599"
  },
  "r19": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(29))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r190": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e8475-108599"
  },
  "r191": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "40",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e9031-108599"
  },
  "r192": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e9038-108599"
  },
  "r193": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e9038-108599"
  },
  "r194": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e9038-108599"
  },
  "r195": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "42",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=123359005&loc=d3e9054-108599"
  },
  "r196": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "280",
   "URI": "http://asc.fasb.org/topic&trid=2134510"
  },
  "r197": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=124259787&loc=d3e4647-111522"
  },
  "r198": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=124259787&loc=d3e4428-111522"
  },
  "r199": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=124259787&loc=d3e4531-111522"
  },
  "r2": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "205",
   "URI": "http://asc.fasb.org/extlink&oid=109222650&loc=SL51721683-107760"
  },
  "r20": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(3)(a)(2))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r200": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=123577603&loc=SL6953423-111524"
  },
  "r201": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=123577603&loc=d3e5074-111524"
  },
  "r202": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=123577603&loc=d3e5111-111524"
  },
  "r203": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=123577603&loc=SL6953401-111524"
  },
  "r204": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB Topic 4.E)",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=122038336&loc=d3e74512-122707"
  },
  "r205": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=124260329&loc=d3e26610-111562"
  },
  "r206": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27161-111563"
  },
  "r207": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(aa)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27161-111563"
  },
  "r208": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27161-111563"
  },
  "r209": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27161-111563"
  },
  "r21": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(3))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r210": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27161-111563"
  },
  "r211": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=123581744&loc=d3e27198-111563"
  },
  "r212": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "320",
   "URI": "http://asc.fasb.org/topic&trid=2196928"
  },
  "r213": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "321",
   "URI": "http://asc.fasb.org/extlink&oid=123583765&loc=SL75117539-209714"
  },
  "r214": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "321",
   "URI": "http://asc.fasb.org/extlink&oid=123583765&loc=SL75117539-209714"
  },
  "r215": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "321",
   "URI": "http://asc.fasb.org/extlink&oid=123583765&loc=SL75117539-209714"
  },
  "r216": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)(1)",
   "Topic": "323",
   "URI": "http://asc.fasb.org/extlink&oid=114001798&loc=d3e33918-111571"
  },
  "r217": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "323",
   "URI": "http://asc.fasb.org/extlink&oid=114001798&loc=d3e33918-111571"
  },
  "r218": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=122640432&loc=SL121648383-210437"
  },
  "r219": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255206&loc=SL82895884-210446"
  },
  "r22": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(30)(a)(1))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r220": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919244-210447"
  },
  "r221": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919249-210447"
  },
  "r222": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919249-210447"
  },
  "r223": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919253-210447"
  },
  "r224": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919269-210447"
  },
  "r225": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919272-210447"
  },
  "r226": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919230-210447"
  },
  "r227": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919230-210447"
  },
  "r228": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124255953&loc=SL82919236-210447"
  },
  "r229": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Subparagraph": "(e)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124267575&loc=SL82921835-210448"
  },
  "r23": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(30)(a)(3))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r230": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "79",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124267575&loc=SL82922352-210448"
  },
  "r231": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "80",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124267575&loc=SL82922355-210448"
  },
  "r232": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124258926&loc=SL82898722-210454"
  },
  "r233": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124269663&loc=SL82922888-210455"
  },
  "r234": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124269663&loc=SL82922895-210455"
  },
  "r235": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Subparagraph": "(g)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=124269663&loc=SL82922900-210455"
  },
  "r236": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB TOPIC 5.BB)",
   "Topic": "330",
   "URI": "http://asc.fasb.org/extlink&oid=27011343&loc=d3e100047-122729"
  },
  "r237": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "40",
   "Subparagraph": "(a)",
   "Topic": "340",
   "URI": "http://asc.fasb.org/extlink&oid=123353750&loc=SL49131252-203054"
  },
  "r238": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Topic": "350",
   "URI": "http://asc.fasb.org/extlink&oid=99380562&loc=d3e13770-109266"
  },
  "r239": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Topic": "350",
   "URI": "http://asc.fasb.org/extlink&oid=120320667&loc=SL49117168-202975"
  },
  "r24": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(30))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r240": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "350",
   "URI": "http://asc.fasb.org/extlink&oid=121556970&loc=d3e13816-109267"
  },
  "r241": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=6391035&loc=d3e2868-110229"
  },
  "r242": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=6391035&loc=d3e2868-110229"
  },
  "r243": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=6391035&loc=d3e2868-110229"
  },
  "r244": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=6391035&loc=d3e2868-110229"
  },
  "r245": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=109226691&loc=d3e2941-110230"
  },
  "r246": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "360",
   "URI": "http://asc.fasb.org/extlink&oid=109226691&loc=d3e2941-110230"
  },
  "r247": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "410",
   "URI": "http://asc.fasb.org/extlink&oid=6392692&loc=d3e7535-110849"
  },
  "r248": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "420",
   "URI": "http://asc.fasb.org/extlink&oid=6394359&loc=d3e17939-110869"
  },
  "r249": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "420",
   "URI": "http://asc.fasb.org/extlink&oid=6394359&loc=d3e17939-110869"
  },
  "r25": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(31))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r250": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB Topic 5.P.4(d))",
   "Topic": "420",
   "URI": "http://asc.fasb.org/extlink&oid=115931487&loc=d3e140904-122747"
  },
  "r251": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "440",
   "URI": "http://asc.fasb.org/extlink&oid=123406679&loc=d3e25336-109308"
  },
  "r252": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "440",
   "URI": "http://asc.fasb.org/extlink&oid=123406679&loc=d3e25336-109308"
  },
  "r253": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "440",
   "URI": "http://asc.fasb.org/topic&trid=2144648"
  },
  "r254": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14326-108349"
  },
  "r255": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14615-108349"
  },
  "r256": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14394-108349"
  },
  "r257": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14435-108349"
  },
  "r258": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14453-108349"
  },
  "r259": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14472-108349"
  },
  "r26": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(32))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r260": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "450",
   "URI": "http://asc.fasb.org/extlink&oid=121557415&loc=d3e14557-108349"
  },
  "r261": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "450",
   "URI": "http://asc.fasb.org/topic&trid=2127136"
  },
  "r262": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "15",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=123389529&loc=d3e10037-110241"
  },
  "r263": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=124440162&loc=d3e12021-110248"
  },
  "r264": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=124440162&loc=d3e12053-110248"
  },
  "r265": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=123408193&loc=d3e13051-110250"
  },
  "r266": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(i))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r267": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(ii))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r268": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(iii)(A))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r269": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(iii)(B))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r27": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(4))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r270": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(iii))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r271": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(4)(iv))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r272": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-01(a)(5))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442526-122756"
  },
  "r273": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(i))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r274": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iii)(A)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r275": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iii)(A))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r276": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iii)(B)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r277": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iii)(B))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r278": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iii)(C))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r279": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(4)(iv))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r28": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(6)(a))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r280": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.13-02(a)(5))",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=124359900&loc=SL124442552-122756"
  },
  "r281": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "25",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466302&loc=d3e4852-112606"
  },
  "r282": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495323-112611"
  },
  "r283": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495323-112611"
  },
  "r284": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495323-112611"
  },
  "r285": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(e)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495323-112611"
  },
  "r286": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1D",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495340-112611"
  },
  "r287": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1D",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495340-112611"
  },
  "r288": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1D",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495340-112611"
  },
  "r289": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1E",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495348-112611"
  },
  "r29": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(6)(b))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r290": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1F",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495355-112611"
  },
  "r291": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1F",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495355-112611"
  },
  "r292": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1F",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)(1)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495355-112611"
  },
  "r293": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1F",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)(2)",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466505&loc=SL123495355-112611"
  },
  "r294": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "69B",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466577&loc=SL123495735-112612"
  },
  "r295": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "69C",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466577&loc=SL123495737-112612"
  },
  "r296": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "69E",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466577&loc=SL123495743-112612"
  },
  "r297": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "69F",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=123466577&loc=SL123495745-112612"
  },
  "r298": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r299": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r3": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6676-107765"
  },
  "r30": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(6)(c))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r300": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r301": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r302": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r303": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(h)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r304": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(i)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r305": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496158-112644"
  },
  "r306": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496171-112644"
  },
  "r307": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496171-112644"
  },
  "r308": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496171-112644"
  },
  "r309": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "16",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496180-112644"
  },
  "r31": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(7))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r310": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496189-112644"
  },
  "r311": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496189-112644"
  },
  "r312": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=SL123496189-112644"
  },
  "r313": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=123467817&loc=d3e21463-112644"
  },
  "r314": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.3-04)",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=120397183&loc=d3e187085-122770"
  },
  "r315": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "505",
   "URI": "http://asc.fasb.org/topic&trid=2208762"
  },
  "r316": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123360276&loc=SL49130531-203044"
  },
  "r317": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123360276&loc=SL49130532-203044"
  },
  "r318": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123360276&loc=SL49130533-203044"
  },
  "r319": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130551-203045"
  },
  "r32": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02(8))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r320": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130551-203045"
  },
  "r321": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130551-203045"
  },
  "r322": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130551-203045"
  },
  "r323": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130554-203045"
  },
  "r324": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130554-203045"
  },
  "r325": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130554-203045"
  },
  "r326": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130554-203045"
  },
  "r327": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130554-203045"
  },
  "r328": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130556-203045"
  },
  "r329": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(1)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130556-203045"
  },
  "r33": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.1)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r330": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(2)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130556-203045"
  },
  "r331": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130558-203045"
  },
  "r332": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130543-203045"
  },
  "r333": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130543-203045"
  },
  "r334": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130545-203045"
  },
  "r335": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130549-203045"
  },
  "r336": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130549-203045"
  },
  "r337": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123351226&loc=SL49130550-203045"
  },
  "r338": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r339": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r34": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.13)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r340": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r341": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r342": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r343": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r344": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123410239&loc=SL49130690-203046-203046"
  },
  "r345": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(i)(1)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=123338486&loc=SL49131195-203048"
  },
  "r346": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "606",
   "URI": "http://asc.fasb.org/topic&trid=49130388"
  },
  "r347": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(i)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r348": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(ii)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r349": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(01)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r35": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.14)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r350": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(02)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r351": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(02)(A)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r352": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(02)(B)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r353": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(02)(C)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r354": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(iv)(03)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r355": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(n)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123447040&loc=d3e1928-114920"
  },
  "r356": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "17",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=123450688&loc=d3e4179-114921"
  },
  "r357": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "80",
   "Subparagraph": "(d)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=65877416&loc=SL14450657-114947"
  },
  "r358": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "80",
   "Subparagraph": "(f)(3)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=65877416&loc=SL14450657-114947"
  },
  "r359": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "80",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=35742348&loc=SL14450788-114948"
  },
  "r36": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.17)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r360": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1D",
   "Publisher": "FASB",
   "Section": "35",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=123468992&loc=SL116886442-113899"
  },
  "r361": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "35",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=123468992&loc=d3e4534-113899"
  },
  "r362": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "35",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=123468992&loc=d3e4549-113899"
  },
  "r363": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5047-113901"
  },
  "r364": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5047-113901"
  },
  "r365": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5047-113901"
  },
  "r366": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)(1)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r367": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)(2)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r368": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)(3)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r369": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a),(g)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r37": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.19(a))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r370": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)(1)(iv)(2)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r371": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r372": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(h)(1)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r373": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(i)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r374": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=d3e5070-113901"
  },
  "r375": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120381028&loc=SL79508275-113901"
  },
  "r376": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=121322162&loc=SL121327923-165333"
  },
  "r377": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(f)(1)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=121322162&loc=SL121327923-165333"
  },
  "r378": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(f)(2)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=121322162&loc=SL121327923-165333"
  },
  "r379": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(g)(2)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=121322162&loc=SL121327923-165333"
  },
  "r38": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.19(b),22(b))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r380": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB Topic 14.F)",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=122041274&loc=d3e301413-122809"
  },
  "r381": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=122142933&loc=d3e11149-113907"
  },
  "r382": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=122142933&loc=d3e11178-113907"
  },
  "r383": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "718",
   "URI": "http://asc.fasb.org/topic&trid=2228938"
  },
  "r384": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "730",
   "URI": "http://asc.fasb.org/extlink&oid=6420194&loc=d3e21568-108373"
  },
  "r385": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=121826272&loc=d3e32672-109319"
  },
  "r386": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)(2)",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=123459177&loc=SL121830611-158277"
  },
  "r387": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)(3)",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=123459177&loc=SL121830611-158277"
  },
  "r388": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB TOPIC 6.I.7)",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=122134291&loc=d3e330036-122817"
  },
  "r389": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=123586238&loc=d3e38679-109324"
  },
  "r39": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.19-26)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r390": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "808",
   "URI": "http://asc.fasb.org/extlink&oid=6931272&loc=SL5834143-161434"
  },
  "r391": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=116870748&loc=SL6758485-165988"
  },
  "r392": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=116870748&loc=SL6758485-165988"
  },
  "r393": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(bb)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=123419778&loc=d3e5710-111685"
  },
  "r394": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=123419778&loc=d3e5710-111685"
  },
  "r395": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "SubTopic": "15",
   "Topic": "815",
   "URI": "http://asc.fasb.org/subtopic&trid=2229187"
  },
  "r396": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(e)(3)",
   "Topic": "815",
   "URI": "http://asc.fasb.org/extlink&oid=123482062&loc=SL123482106-238011"
  },
  "r397": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(e)(4)",
   "Topic": "815",
   "URI": "http://asc.fasb.org/extlink&oid=123482062&loc=SL123482106-238011"
  },
  "r398": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(f)",
   "Topic": "815",
   "URI": "http://asc.fasb.org/extlink&oid=123482062&loc=SL123482106-238011"
  },
  "r399": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=123874694&loc=d3e19207-110258"
  },
  "r4": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6676-107765"
  },
  "r40": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.20)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r400": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=123874694&loc=d3e19207-110258"
  },
  "r401": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(bb)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=123874694&loc=d3e19207-110258"
  },
  "r402": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=123874694&loc=d3e19279-110258"
  },
  "r403": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "820",
   "URI": "http://asc.fasb.org/topic&trid=2155941"
  },
  "r404": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=123594938&loc=d3e13531-108611"
  },
  "r405": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=123594938&loc=d3e13537-108611"
  },
  "r406": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=123594938&loc=d3e13537-108611"
  },
  "r407": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=123596393&loc=d3e14064-108612"
  },
  "r408": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "230",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=123444420&loc=d3e33268-110906"
  },
  "r409": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "17",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=118261656&loc=d3e32136-110900"
  },
  "r41": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.21)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r410": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Subparagraph": "(a)",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=118261656&loc=d3e32211-110900"
  },
  "r411": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Subparagraph": "(b)",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=118261656&loc=d3e32211-110900"
  },
  "r412": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Subparagraph": "(c)",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=118261656&loc=d3e32211-110900"
  },
  "r413": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Subparagraph": "(d)",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=118261656&loc=d3e32211-110900"
  },
  "r414": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=6450520&loc=d3e32583-110901"
  },
  "r415": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123391704&loc=SL77918627-209977"
  },
  "r416": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123391704&loc=SL77918627-209977"
  },
  "r417": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123391704&loc=SL77918638-209977"
  },
  "r418": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123391704&loc=SL77918643-209977"
  },
  "r419": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123391704&loc=SL77918643-209977"
  },
  "r42": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.22(a)(1))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r420": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)(3)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918673-209980"
  },
  "r421": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918673-209980"
  },
  "r422": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r423": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r424": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r425": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r426": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(e)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r427": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(1)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r428": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(3)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r429": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(4)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r43": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.24)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r430": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918686-209980"
  },
  "r431": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123408670&loc=SL77918701-209980"
  },
  "r432": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "53",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=123414884&loc=SL77918982-209971"
  },
  "r433": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "845",
   "URI": "http://asc.fasb.org/extlink&oid=123385986&loc=d3e32049-108421"
  },
  "r434": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39549-107864"
  },
  "r435": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39549-107864"
  },
  "r436": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39549-107864"
  },
  "r437": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39549-107864"
  },
  "r438": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39549-107864"
  },
  "r439": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39599-107864"
  },
  "r44": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.25)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r440": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39603-107864"
  },
  "r441": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "850",
   "URI": "http://asc.fasb.org/extlink&oid=6457730&loc=d3e39691-107864"
  },
  "r442": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "850",
   "URI": "http://asc.fasb.org/topic&trid=2122745"
  },
  "r443": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "852",
   "URI": "http://asc.fasb.org/extlink&oid=124433192&loc=SL2890621-112765"
  },
  "r444": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "852",
   "URI": "http://asc.fasb.org/extlink&oid=124433192&loc=SL2890621-112765"
  },
  "r445": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Topic": "852",
   "URI": "http://asc.fasb.org/extlink&oid=84165509&loc=d3e56426-112766"
  },
  "r446": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "855",
   "URI": "http://asc.fasb.org/extlink&oid=6842918&loc=SL6314020-165662"
  },
  "r447": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(bb)(1)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r448": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(bb)(2)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r449": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(bb)(3)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r45": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.29)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r450": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)(1)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r451": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)(2)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r452": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)(3)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107207-111719"
  },
  "r453": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)(1)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107314-111719"
  },
  "r454": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)(2)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107314-111719"
  },
  "r455": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)(3)",
   "Topic": "860",
   "URI": "http://asc.fasb.org/extlink&oid=121570589&loc=d3e107314-111719"
  },
  "r456": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "910",
   "URI": "http://asc.fasb.org/extlink&oid=123353855&loc=SL119991595-234733"
  },
  "r457": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "310",
   "Subparagraph": "(b)",
   "Topic": "912",
   "URI": "http://asc.fasb.org/extlink&oid=123371682&loc=d3e55415-109406"
  },
  "r458": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "25",
   "SubTopic": "730",
   "Topic": "912",
   "URI": "http://asc.fasb.org/extlink&oid=6472174&loc=d3e58812-109433"
  },
  "r459": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SAB Topic 11.L)",
   "Topic": "924",
   "URI": "http://asc.fasb.org/extlink&oid=6472922&loc=d3e499488-122856"
  },
  "r46": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.29-31)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r460": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "25",
   "SubTopic": "20",
   "Topic": "940",
   "URI": "http://asc.fasb.org/extlink&oid=123384075&loc=d3e41242-110953"
  },
  "r461": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "820",
   "Topic": "940",
   "URI": "http://asc.fasb.org/extlink&oid=35710923&loc=d3e45360-110995"
  },
  "r462": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(1)(a))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r463": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(10)(1))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r464": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(11))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r465": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(16))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r466": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(17))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r467": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(23))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r468": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03(6))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r469": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03.15(5))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r47": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.3,4)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r470": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.9-03.17)",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120398452&loc=d3e534808-122878"
  },
  "r471": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.9-04(15))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120399700&loc=SL114874048-224260"
  },
  "r472": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.9-04(22))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120399700&loc=SL114874048-224260"
  },
  "r473": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.9-04(27))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120399700&loc=SL114874048-224260"
  },
  "r474": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "235",
   "Subparagraph": "(SX 210.9-05(b)(1))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120399901&loc=d3e537907-122884"
  },
  "r475": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "235",
   "Subparagraph": "(SX 210.9-05(b)(2))",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120399901&loc=d3e537907-122884"
  },
  "r476": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "320",
   "Subparagraph": "(a)",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=123599081&loc=SL120269850-112803"
  },
  "r477": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "360",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=124429447&loc=SL124453093-239630"
  },
  "r478": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(5))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r479": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(12))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r48": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.6(a)(1))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r480": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(16))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r481": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(19))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r482": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(2))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r483": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(23)(a)(4))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r484": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(25))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r485": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(3))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r486": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03(a)(8))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r487": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03.(a)(19))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r488": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03.(a),19)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r489": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "210",
   "Subparagraph": "(SX 210.7-03.15(a))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400017&loc=d3e572229-122910"
  },
  "r49": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.6(a)(3))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r490": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.7-04(18))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400993&loc=SL114874131-224263"
  },
  "r491": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.7-04(23))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400993&loc=SL114874131-224263"
  },
  "r492": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.7-04(8))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400993&loc=SL114874131-224263"
  },
  "r493": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.7-04(9))",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=120400993&loc=SL114874131-224263"
  },
  "r494": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4H",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "40",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=116884468&loc=SL65671331-158438"
  },
  "r495": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "40",
   "Subparagraph": "(d)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124506351&loc=SL117782755-158439"
  },
  "r496": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(a)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124504033&loc=SL117783719-158441"
  },
  "r497": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(b)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124504033&loc=SL117783719-158441"
  },
  "r498": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(c)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124504033&loc=SL117783719-158441"
  },
  "r499": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29F",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124504033&loc=SL117819544-158441"
  },
  "r5": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6676-107765"
  },
  "r50": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.6(a)(4))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r500": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(e)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124501264&loc=SL117420844-207641"
  },
  "r501": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(f)(1)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124501264&loc=SL117420844-207641"
  },
  "r502": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(f)(2)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124501264&loc=SL117420844-207641"
  },
  "r503": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(g)(2)(i)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124501264&loc=SL117420844-207641"
  },
  "r504": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(h)(2)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=124501264&loc=SL117420844-207641"
  },
  "r505": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "825",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=123600520&loc=SL75241803-196195"
  },
  "r506": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "210",
   "Subparagraph": "(c)",
   "Topic": "946",
   "URI": "http://asc.fasb.org/extlink&oid=99383244&loc=d3e12121-115841"
  },
  "r507": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "220",
   "Subparagraph": "(SX 210.6-07.1(c))",
   "Topic": "946",
   "URI": "http://asc.fasb.org/extlink&oid=120401555&loc=SL114874292-224272"
  },
  "r508": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "320",
   "Subparagraph": "(SX 210.12-12B(Column B))",
   "Topic": "946",
   "URI": "http://asc.fasb.org/extlink&oid=122147990&loc=d3e611197-123010"
  },
  "r509": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "310",
   "Subparagraph": "(SX 210.12-29(Footnote 4))",
   "Topic": "948",
   "URI": "http://asc.fasb.org/extlink&oid=120402547&loc=d3e617274-123014"
  },
  "r51": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.6(a))",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r510": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "210",
   "Topic": "954",
   "URI": "http://asc.fasb.org/extlink&oid=120413173&loc=SL6242262-115580"
  },
  "r511": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "210",
   "Topic": "954",
   "URI": "http://asc.fasb.org/extlink&oid=120413173&loc=SL116631458-115580"
  },
  "r512": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "210",
   "Topic": "954",
   "URI": "http://asc.fasb.org/extlink&oid=120413209&loc=SL6242269-115581"
  },
  "r513": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "310",
   "Topic": "954",
   "URI": "http://asc.fasb.org/extlink&oid=123364037&loc=d3e3115-115594"
  },
  "r514": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "440",
   "Subparagraph": "(a)",
   "Topic": "954",
   "URI": "http://asc.fasb.org/extlink&oid=6491277&loc=d3e6429-115629"
  },
  "r515": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column B))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r516": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column C))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r517": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column D))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r518": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column E))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r519": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column F))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r52": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.8,17)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r520": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column G))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r521": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column H))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r522": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Column I))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r523": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Footnote 2))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r524": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "360",
   "Subparagraph": "(SX 210.12-28(Footnote 5))",
   "Topic": "970",
   "URI": "http://asc.fasb.org/extlink&oid=120402810&loc=d3e638233-123024"
  },
  "r525": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "310",
   "Subparagraph": "(c)",
   "Topic": "976",
   "URI": "http://asc.fasb.org/extlink&oid=6497875&loc=d3e22274-108663"
  },
  "r526": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "310",
   "Subparagraph": "(b)",
   "Topic": "978",
   "URI": "http://asc.fasb.org/extlink&oid=123360121&loc=d3e27327-108691"
  },
  "r527": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "985",
   "URI": "http://asc.fasb.org/extlink&oid=6501960&loc=d3e128462-111756"
  },
  "r528": {
   "Name": "Exchange Act",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "b"
  },
  "r529": {
   "Name": "Exchange Act",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "d1-1"
  },
  "r53": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-02.9)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=120391452&loc=d3e13212-122682"
  },
  "r530": {
   "Name": "Form 10-Q",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "308",
   "Subsection": "a"
  },
  "r531": {
   "Name": "Forms 10-K, 10-Q, 20-F",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "13",
   "Subsection": "a-1"
  },
  "r532": {
   "Name": "Regulation 12B",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "b-2"
  },
  "r533": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1402"
  },
  "r534": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(b)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(1)"
  },
  "r535": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(b)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(2)"
  },
  "r536": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(b)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(3)"
  },
  "r537": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(b)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(4)"
  },
  "r538": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(b)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(5)"
  },
  "r539": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(1)(i)"
  },
  "r54": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "16",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=99393222&loc=SL20226024-175313"
  },
  "r540": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(1)(ii)"
  },
  "r541": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(2)(i)"
  },
  "r542": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(2)(ii)"
  },
  "r543": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1402",
   "Subparagraph": "(2)(iii)"
  },
  "r544": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Publisher": "SEC",
   "Section": "1402",
   "Subsection": "Instruction 5"
  },
  "r545": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1404"
  },
  "r546": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1405",
   "Subparagraph": "(1)"
  },
  "r547": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1405",
   "Subparagraph": "(2)"
  },
  "r548": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1405"
  },
  "r549": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1406",
   "Subparagraph": "(1)"
  },
  "r55": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=99393222&loc=SL20226049-175313"
  },
  "r550": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1406",
   "Subparagraph": "(2)"
  },
  "r551": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1406",
   "Subparagraph": "(3)"
  },
  "r552": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1406",
   "Subparagraph": "(4)"
  },
  "r553": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(a)",
   "Publisher": "SEC",
   "Section": "1406",
   "Subparagraph": "(5)"
  },
  "r554": {
   "Name": "Regulation S-K (SK)",
   "Number": "229",
   "Paragraph": "(c)",
   "Publisher": "SEC",
   "Section": "1406"
  },
  "r555": {
   "Name": "Regulation S-T",
   "Number": "232",
   "Publisher": "SEC",
   "Section": "405"
  },
  "r556": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(a)(3)(iii)(03)",
   "Topic": "848"
  },
  "r56": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=99393222&loc=SL20226052-175313"
  },
  "r57": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=124509347&loc=SL7669619-108580"
  },
  "r58": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=124509347&loc=SL7669625-108580"
  },
  "r59": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=124431353&loc=SL124442407-227067"
  },
  "r6": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6676-107765"
  },
  "r60": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=124431353&loc=SL124442411-227067"
  },
  "r61": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=124431353&loc=SL124452729-227067"
  },
  "r62": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03(10))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r63": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03(20))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r64": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03(25))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r65": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03(5))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r66": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r67": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.1(e))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r68": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.2(a),(d))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r69": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.4)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r7": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6801-107765"
  },
  "r70": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.7(b))",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r71": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.8)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r72": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.5-03.9)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=123367319&loc=SL114868664-224227"
  },
  "r73": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3179-108585"
  },
  "r74": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3213-108585"
  },
  "r75": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3213-108585"
  },
  "r76": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3255-108585"
  },
  "r77": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3291-108585"
  },
  "r78": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3291-108585"
  },
  "r79": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "17",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3367-108585"
  },
  "r8": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6812-107765"
  },
  "r80": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "24",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3521-108585"
  },
  "r81": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3536-108585"
  },
  "r82": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3536-108585"
  },
  "r83": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3536-108585"
  },
  "r84": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3536-108585"
  },
  "r85": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3536-108585"
  },
  "r86": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3602-108585"
  },
  "r87": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3602-108585"
  },
  "r88": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3602-108585"
  },
  "r89": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123570139&loc=d3e3044-108585"
  },
  "r9": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=124098289&loc=d3e6812-107765"
  },
  "r90": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123431023&loc=d3e4297-108586"
  },
  "r91": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123431023&loc=d3e4304-108586"
  },
  "r92": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123431023&loc=d3e4313-108586"
  },
  "r93": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123431023&loc=d3e4332-108586"
  },
  "r94": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=123431023&loc=SL98516268-108586"
  },
  "r95": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=123372394&loc=d3e18726-107790"
  },
  "r96": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(d))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r97": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(e)(1))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r98": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(g)(1)(ii))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r99": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(h))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  }
 },
 "version": "2.1"
}
