{
 "instance": {
  "cdxs-20210331.htm": {
   "axisCustom": 1,
   "axisStandard": 33,
   "contextCount": 226,
   "dts": {
    "calculationLink": {
     "local": [
      "cdxs-20210331_cal.xml"
     ]
    },
    "definitionLink": {
     "local": [
      "cdxs-20210331_def.xml"
     ],
     "remote": [
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-gaap-eedm-def-2020-01-31.xml",
      "http://xbrl.fasb.org/srt/2020/elts/srt-eedm1-def-2020-01-31.xml"
     ]
    },
    "inline": {
     "local": [
      "cdxs-20210331.htm"
     ]
    },
    "labelLink": {
     "local": [
      "cdxs-20210331_lab.xml"
     ],
     "remote": [
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-gaap-doc-2020-01-31.xml",
      "https://xbrl.sec.gov/dei/2020/dei-doc-2020-01-31.xml"
     ]
    },
    "presentationLink": {
     "local": [
      "cdxs-20210331_pre.xml"
     ]
    },
    "referenceLink": {
     "remote": [
      "https://xbrl.sec.gov/dei/2020/dei-ref-2020-01-31.xml",
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-gaap-ref-2020-01-31.xml"
     ]
    },
    "schema": {
     "local": [
      "cdxs-20210331.xsd"
     ],
     "remote": [
      "http://xbrl.fasb.org/srt/2020/elts/srt-2020-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",
      "http://www.xbrl.org/dtr/type/numeric-2009-12-16.xsd",
      "http://www.xbrl.org/dtr/type/nonNumeric-2009-12-16.xsd",
      "http://www.xbrl.org/2005/xbrldt-2005.xsd",
      "http://www.xbrl.org/2006/ref-2006-02-27.xsd",
      "http://xbrl.fasb.org/srt/2020/elts/srt-types-2020-01-31.xsd",
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-gaap-2020-01-31.xsd",
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-roles-2020-01-31.xsd",
      "http://xbrl.fasb.org/srt/2020/elts/srt-roles-2020-01-31.xsd",
      "https://xbrl.sec.gov/country/2020/country-2020-01-31.xsd",
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-types-2020-01-31.xsd",
      "https://xbrl.sec.gov/dei/2020/dei-2020-01-31.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/deprecated-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/reference-2009-12-16.xsd",
      "http://xbrl.fasb.org/us-gaap/2020/elts/us-parts-codification-2020-01-31.xsd"
     ]
    }
   },
   "elementCount": 481,
   "entityCount": 1,
   "hidden": {
    "http://fasb.org/us-gaap/2020-01-31": 13,
    "http://xbrl.sec.gov/dei/2020-01-31": 5,
    "total": 18
   },
   "keyCustom": 13,
   "keyStandard": 312,
   "memberCustom": 39,
   "memberStandard": 42,
   "nsprefix": "cdxs",
   "nsuri": "http://www.codexis.com/20210331",
   "report": {
    "R1": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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 Loss per Share",
     "role": "http://www.codexis.com/role/NetLossperShare",
     "shortName": "Net Loss per Share",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentsInDebtAndEquityInstrumentsCashAndCashEquivalentsUnrealizedAndRealizedGainsLossesTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2115105 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueMeasurementInputsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2119106 - Disclosure - Fair Value Measurements",
     "role": "http://www.codexis.com/role/FairValueMeasurements",
     "shortName": "Fair Value Measurements",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "cdxs:BalanceSheetsDetailsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2122107 - Disclosure - Balance Sheets Details",
     "role": "http://www.codexis.com/role/BalanceSheetsDetails",
     "shortName": "Balance Sheets Details",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2129108 - Disclosure - Stock-based Compensation",
     "role": "http://www.codexis.com/role/StockbasedCompensation",
     "shortName": "Stock-based Compensation",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:StockholdersEquityNoteDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2136109 - Disclosure - Capital Stock",
     "role": "http://www.codexis.com/role/CapitalStock",
     "shortName": "Capital Stock",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CommitmentsAndContingenciesDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2138110 - Disclosure - Commitments and Contingencies",
     "role": "http://www.codexis.com/role/CommitmentsandContingencies",
     "shortName": "Commitments and Contingencies",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RelatedPartyTransactionsDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2147111 - Disclosure - Related Party Transactions",
     "role": "http://www.codexis.com/role/RelatedPartyTransactions",
     "shortName": "Related Party Transactions",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SegmentReportingDisclosureTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2150112 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CreditLossFinancialInstrumentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2158113 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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",
     "role": "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
     "shortName": "Condensed Consolidated Balance Sheets",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RestrictedCash",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R20": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SubsequentEventsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2162114 - Disclosure - Subsequent Event",
     "role": "http://www.codexis.com/role/SubsequentEvent",
     "shortName": "Subsequent Event",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SubsequentEventsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R21": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:BasisOfAccountingPolicyPolicyTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R22": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DisaggregationOfRevenueTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R23": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2313302 - Disclosure - Net Loss per Share (Tables)",
     "role": "http://www.codexis.com/role/NetLossperShareTables",
     "shortName": "Net Loss per Share (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R24": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2316303 - 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": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R25": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2320304 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R26": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfCashAndCashEquivalentsTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2323305 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfCashAndCashEquivalentsTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R27": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2330306 - Disclosure - Stock-based Compensation (Tables)",
     "role": "http://www.codexis.com/role/StockbasedCompensationTables",
     "shortName": "Stock-based Compensation (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R28": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LeaseCostTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2339307 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LeaseCostTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R29": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2351308 - 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": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R3": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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 (Parenthetical)",
     "role": "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical",
     "shortName": "Condensed Consolidated Balance Sheets (Parenthetical)",
     "subGroupType": "parenthetical",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PreferredStockParOrStatedValuePerShare",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usdPerShare",
      "xsiNil": "false"
     }
    },
    "R30": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2359309 - Disclosure - Allowance for Credit Losses (Tables)",
     "role": "http://www.codexis.com/role/AllowanceforCreditLossesTables",
     "shortName": "Allowance for Credit Losses (Tables)",
     "subGroupType": "tables",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R31": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i8f1bfbcea76f4ae08d7f30bd7d949549_D20190101-20190331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInMeasureOfProgress",
      "reportCount": 1,
      "unique": true,
      "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-20210331.htm",
      "contextRef": "i8f1bfbcea76f4ae08d7f30bd7d949549_D20190101-20190331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInMeasureOfProgress",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R32": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "i63b975055202431181911cd1061504fd_D20210101-20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R33": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ContractWithCustomerAssetAndLiabilityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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",
       "div",
       "us-gaap:ContractWithCustomerAssetAndLiabilityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:CapitalizedContractCostNetCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R34": {
     "firstAnchor": {
      "ancestors": [
       "us-gaap:ContractWithCustomerAssetCreditLossExpense",
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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 - Textual (Details)",
     "role": "http://www.codexis.com/role/RevenueRecognitionTextualDetails",
     "shortName": "Revenue Recognition - Textual (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "us-gaap:ContractWithCustomerAssetCreditLossExpense",
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerAssetCreditLossExpense",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R35": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "ix:continuation",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerLiabilityRevenueRecognized",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R36": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueRemainingPerformanceObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R37": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ic92757b625b6469eb4b9a32d22686cc3_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2414407 - Disclosure - Net Loss per Share (Details)",
     "role": "http://www.codexis.com/role/NetLossperShareDetails",
     "shortName": "Net Loss per Share (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ic92757b625b6469eb4b9a32d22686cc3_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentIncomeAmortizationOfDiscount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2417408 - Disclosure - Investments in Non-Marketable Securities - Textual (Details)",
     "role": "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails",
     "shortName": "Investments in Non-Marketable Securities - Textual (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentIncomeAmortizationOfDiscount",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R39": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleDebtSecuritiesAmortizedCostBasis",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2418409 - 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",
       "div",
       "us-gaap:DebtSecuritiesAvailableForSaleTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleDebtSecuritiesAmortizedCostBasis",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R4": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
     "shortName": "Condensed Consolidated Statements of Operations",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:InvestmentIncomeInterest",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R40": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:FairValueAssetsMeasuredOnRecurringBasisTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AvailableForSaleSecuritiesDebtSecurities",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2421410 - 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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:CashAndCashEquivalentsAtCarryingValue",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2424411 - 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-20210331.htm",
      "contextRef": "ie9092d081f1d412d9260d45d4b32b681_I20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:CashAndCashEquivalentsAtCarryingValue",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R42": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ScheduleOfInventoryCurrentTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InventoryRawMaterials",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2425412 - 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",
       "div",
       "us-gaap:ScheduleOfInventoryCurrentTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PropertyPlantAndEquipmentGross",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2426413 - 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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2427414 - 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",
       "div",
       "us-gaap:ScheduleOfAccruedLiabilitiesTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:PurchaseObligation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2428415 - 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",
       "div",
       "us-gaap:ScheduleOfAccruedLiabilitiesTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "i67eefd45c89f4af1a1d505d172f79480_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": "2431416 - 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-20210331.htm",
      "contextRef": "i67eefd45c89f4af1a1d505d172f79480_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-20210331.htm",
      "contextRef": "ia13cb4d69d364646aa0b84a193755b6e_D20210101-20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SharebasedCompensationArrangementBySharebasedPaymentAwardPurchasePriceOfCommonStockPercent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2432417 - 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-20210331.htm",
      "contextRef": "ia13cb4d69d364646aa0b84a193755b6e_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "iad7adb604191443daaa44ee779b7605d_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2433418 - 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-20210331.htm",
      "contextRef": "iad7adb604191443daaa44ee779b7605d_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "iae9b3be64ec940668bb607bd97da2631_I20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "cdxs:SharebasedCompensationArrangementbySharebasedPaymentAwardNumberofInstallments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "installment",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2434419 - 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-20210331.htm",
      "contextRef": "iae9b3be64ec940668bb607bd97da2631_I20210331",
      "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-20210331.htm",
      "contextRef": "if0d30f3d11aa4ef2936ea67e9a204542_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",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity",
     "shortName": "Condensed Consolidated Statements of Stockholders' Equity",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if0d30f3d11aa4ef2936ea67e9a204542_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",
       "div",
       "us-gaap:ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensation",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2435420 - 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",
       "div",
       "us-gaap:ScheduleOfSharebasedCompensationRestrictedStockAndRestrictedStockUnitsActivityTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i08c0e36ff0dd4095bf5909bf906c9bba_D20210101-20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:ShareBasedCompensation",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R51": {
     "firstAnchor": {
      "ancestors": [
       "ix:continuation",
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:StockIssuedDuringPeriodSharesStockOptionsExercised",
      "reportCount": 1,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2437421 - Disclosure - Capital Stock (Details)",
     "role": "http://www.codexis.com/role/CapitalStockDetails",
     "shortName": "Capital Stock (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "ix:continuation",
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-2",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AreaOfRealEstateProperty",
      "reportCount": 1,
      "unique": true,
      "unitRef": "sqft",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2440422 - Disclosure - Commitments and Contingencies - Textual (Details)",
     "role": "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails",
     "shortName": "Commitments and Contingencies - Textual (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-2",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FinanceLeaseRightOfUseAssetAmortization",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2441423 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeaseWeightedAverageRemainingLeaseTerm1",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2442424 - 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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:OperatingLeasePayments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2443425 - 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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2444426 - 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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "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 - 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",
       "us-gaap:FinanceLeaseLiabilityMaturityTableTextBlock",
       "ix:continuation",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ib232e8934a3246d6a4508c0e240c18bf_I20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R58": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:SupplyCommitmentTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if8273754a3ff4c1baaefdfea7b121aaa_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:SignificantSupplyCommitmentRemainingMinimumAmountCommitted",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2446428 - 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",
       "div",
       "us-gaap:SupplyCommitmentTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if8273754a3ff4c1baaefdfea7b121aaa_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentsAndOtherNoncurrentAssets",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2448429 - 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-20210331.htm",
      "contextRef": "ic910d5787fb44e71a100151a8bb54ede_I20201231",
      "decimals": "-5",
      "lang": "en-US",
      "name": "us-gaap:ContractWithCustomerAssetGrossCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R6": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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",
     "role": "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows",
     "shortName": "Condensed Consolidated Statements of Cash Flows",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:OperatingLeaseRightOfUseAssetAmortizationExpense",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R60": {
     "firstAnchor": {
      "ancestors": [
       "us-gaap:RevenueFromRelatedParties",
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i6094c02d73d244c1a331496607e6bab2_D20200101-20200331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromRelatedParties",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2449430 - 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": [
       "us-gaap:RevenueFromRelatedParties",
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i6094c02d73d244c1a331496607e6bab2_D20200101-20200331",
      "decimals": "-5",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromRelatedParties",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R61": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "us-gaap:SegmentReportingPolicyPolicyTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NumberOfOperatingSegments",
      "reportCount": 1,
      "unique": true,
      "unitRef": "segment",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2452431 - Disclosure - Segment, Geographical and Other Revenue Information - Textual (Details)",
     "role": "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTextualDetails",
     "shortName": "Segment, Geographical and Other Revenue Information - Textual (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "div",
       "us-gaap:SegmentReportingPolicyPolicyTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2453432 - 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",
       "div",
       "us-gaap:ScheduleOfSegmentReportingInformationBySegmentTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ica53be3509544e0995bc13715b7dab00_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "i1cc9019ca863405fbb9df68277d34082_D20210101-20210331",
      "decimals": "2",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:ConcentrationRiskPercentage1",
      "reportCount": 1,
      "unique": true,
      "unitRef": "number",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2454433 - 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-20210331.htm",
      "contextRef": "i1cc9019ca863405fbb9df68277d34082_D20210101-20210331",
      "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",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerExcludingAssessedTax",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2455434 - 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": null
    },
    "R65": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i491e464c55254313a029addeb98196e5_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:NoncurrentAssets",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2456435 - 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",
       "div",
       "us-gaap:ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i491e464c55254313a029addeb98196e5_I20210331",
      "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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2457436 - 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",
       "div",
       "us-gaap:ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i78c143bfcdc944f3b8551084bfbb5d94_I20210331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:Goodwill",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R67": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:AllowanceForNotesAndLoansReceivableCurrent",
      "reportCount": 1,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2460437 - 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": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i50e90a6f5c854ff4a568a20166e32d76_I20200331",
      "decimals": "-3",
      "lang": "en-US",
      "name": "us-gaap:AllowanceForNotesAndLoansReceivableCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R68": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "us-gaap:PastDueFinancingReceivablesTableTextBlock",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FinancingReceivableRecordedInvestmentCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2461438 - 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-20210331.htm",
      "contextRef": "if157c161802a499a9df9f2822a89451e_I20210331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:FinancingReceivableRecordedInvestmentCurrent",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    },
    "R69": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "ix:continuation",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ib4513dd9b8874a0eb315ee2a6c008420_I20200630",
      "decimals": "INF",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:InvestmentOwnedBalanceShares",
      "reportCount": 1,
      "unitRef": "shares",
      "xsiNil": "false"
     },
     "groupType": "disclosure",
     "isDefault": "false",
     "longName": "2463439 - Disclosure - Subsequent Event (Details)",
     "role": "http://www.codexis.com/role/SubsequentEventDetails",
     "shortName": "Subsequent Event (Details)",
     "subGroupType": "details",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "ix:continuation",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i461a484c5dde4142a7508aa43908c241_I20210430",
      "decimals": "-5",
      "lang": "en-US",
      "name": "us-gaap:InvestmentOwnedBalanceShares",
      "reportCount": 1,
      "unique": true,
      "unitRef": "shares",
      "xsiNil": "false"
     }
    },
    "R7": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "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-20210331.htm",
      "contextRef": "ifa68508bbe4a485795d111a930d3faeb_D20210101-20210331",
      "decimals": null,
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RevenueFromContractWithCustomerTextBlock",
      "reportCount": 1,
      "unique": true,
      "unitRef": null,
      "xsiNil": "false"
     }
    },
    "R9999": {
     "firstAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i50e90a6f5c854ff4a568a20166e32d76_I20200331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RestrictedCashAndCashEquivalents",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     },
     "groupType": "",
     "isDefault": "false",
     "longName": "Uncategorized Items - cdxs-20210331.htm",
     "role": "http://xbrl.sec.gov/role/uncategorizedFacts",
     "shortName": "Uncategorized Items - cdxs-20210331.htm",
     "subGroupType": "",
     "uniqueAnchor": {
      "ancestors": [
       "span",
       "td",
       "tr",
       "table",
       "div",
       "body",
       "html"
      ],
      "baseRef": "cdxs-20210331.htm",
      "contextRef": "i50e90a6f5c854ff4a568a20166e32d76_I20200331",
      "decimals": "-3",
      "first": true,
      "lang": "en-US",
      "name": "us-gaap:RestrictedCashAndCashEquivalents",
      "reportCount": 1,
      "unique": true,
      "unitRef": "usd",
      "xsiNil": "false"
     }
    }
   },
   "segmentCount": 82,
   "tag": {
    "cdxs_A101SaginawMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "101 Saginaw",
        "label": "101 Saginaw [Member]",
        "terseLabel": "101 Saginaw [Member]"
       }
      }
     },
     "localname": "A101SaginawMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A200220PenobscotMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "200-220 Penobscot",
        "label": "200-220 Penobscot [Member]",
        "terseLabel": "200-220 Penobscot [Member]"
       }
      }
     },
     "localname": "A200220PenobscotMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "A2019PSUandPBOPlanMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "A2019PlanMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "A2020PSUAndPBOPlanMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A2021PSUAnd2021PBOMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "2021 PSU And 2021 PBO",
        "label": "2021 PSU And 2021 PBO [Member]",
        "terseLabel": "2021 PSU And 2021 PBO [Member]"
       }
      }
     },
     "localname": "A2021PSUAnd2021PBOMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "A400PenoscotMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_A501ChesapeakeMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "501 Chesapeake",
        "label": "501 Chesapeake [Member]",
        "terseLabel": "501 Chesapeake [Member]"
       }
      }
     },
     "localname": "A501ChesapeakeMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "APACMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "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/20210331",
     "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/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "April2016Member",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_AssetsReceivedForResearchAndDevelopmentRevenueEarned": {
     "auth_ref": [],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Assets Received For Research And Development Revenue Earned",
        "label": "Assets Received For Research And Development Revenue Earned",
        "terseLabel": "Assets received for research and development revenue earned"
       }
      }
     },
     "localname": "AssetsReceivedForResearchAndDevelopmentRevenueEarned",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_BalanceSheetDetailsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Balance Sheet Details [Abstract]",
        "label": "Balance Sheet Details [Abstract]",
        "terseLabel": "Balance Sheet Details [Abstract]"
       }
      }
     },
     "localname": "BalanceSheetDetailsAbstract",
     "nsuri": "http://www.codexis.com/20210331",
     "xbrltype": "stringItemType"
    },
    "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/20210331",
     "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/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "BiotherapeuticSegmentMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_CDX6114Member": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "CDX-6114 [Member]",
        "label": "CDX-6114 [Member]",
        "terseLabel": "CDX-6114 [Member]"
       }
      }
     },
     "localname": "CDX6114Member",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CoreSegmentMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerAMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerBMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerCMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerDMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerEMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_IncentiveStockOptionsMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Incentive Stock Options [Member]",
        "label": "Incentive Stock Options [Member]",
        "terseLabel": "Incentive Stock Options [Member]"
       }
      }
     },
     "localname": "IncentiveStockOptionsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockOptionsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_IncreaseDecreaseInEmployeeRelatedLiabilitiesAndOtherAccruedLiabilities": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/20210331",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "cdxs_LaboratoryEquipmentMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Laboratory Equipment [Member]",
        "label": "Laboratory Equipment [Member]",
        "terseLabel": "Laboratory equipment [Member]"
       }
      }
     },
     "localname": "LaboratoryEquipmentMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_LesseeOperatingLeaseLiabilityToBePaidAfterYearFour": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 5.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": "Thereafter",
        "verboseLabel": "2026 and thereafter"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityToBePaidAfterYearFour",
     "nsuri": "http://www.codexis.com/20210331",
     "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/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "MasterCollaborationResearchAgreementMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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. [Member]"
       }
      }
     },
     "localname": "MolecularAssembliesIncMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_NestecLtd.NestleHealthSciencesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Nestec Ltd. (Nestle Health Sciences) [Member]",
        "label": "Nestec Ltd. (Nestle Health Sciences) [Member]",
        "terseLabel": "Nestec Ltd. (Nestle Health Sciences) [Member]"
       }
      }
     },
     "localname": "NestecLtd.NestleHealthSciencesMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "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": "Unrealized or realized gains or losses"
       }
      }
     },
     "localname": "NonMarketableDebtSecuritiesWithoutReadilyDeterminableFairValueAnnualAmount",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "NonStatutoryStockOptionsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "NovelBiotherapeuticsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "OfficeEquipmentAndFurnitureMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "PerformanceBasedOptionsPBOsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "PerformanceEnzymesMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "PerformanceStockUnitsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_ProductSalesMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Product Sales [Member]",
        "label": "Product Sales [Member]",
        "terseLabel": "Product Revenue [Member]"
       }
      }
     },
     "localname": "ProductSalesMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "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 [Member]"
       }
      }
     },
     "localname": "RSAsandRSUsMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "ResearchandDevelopmentRevenueMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_SanCarlosMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "San Carlos",
        "label": "San Carlos [Member]",
        "terseLabel": "San Carlos [Member]"
       }
      }
     },
     "localname": "SanCarlosMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "cdxs_SecurityOwnedNotReadilyMarketableMAIMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Security Owned Not Readily Marketable MAI",
        "label": "Security Owned Not Readily Marketable MAI [Member]",
        "terseLabel": "Security Owned Not Readily Marketable MAI [Member]"
       }
      }
     },
     "localname": "SecurityOwnedNotReadilyMarketableMAIMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_September2019Member": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "September 2019 [Member]",
        "label": "September 2019 [Member]",
        "terseLabel": "September 2019 [Member]"
       }
      }
     },
     "localname": "September2019Member",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/20210331",
     "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/20210331",
     "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/20210331",
     "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/20210331",
     "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"
       }
      }
     },
     "localname": "SharesReceivedInExchangeForServicesRendered",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "cdxs_SubleaseMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Sublease",
        "label": "Sublease [Member]",
        "terseLabel": "Sublease [Member]"
       }
      }
     },
     "localname": "SubleaseMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "cdxs_TakedaPharmaceuticalCoLtdMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Takeda Pharmaceutical Co. Ltd.",
        "label": "Takeda Pharmaceutical Co. Ltd. [Member]",
        "terseLabel": "Takeda [Member]"
       }
      }
     },
     "localname": "TakedaPharmaceuticalCoLtdMember",
     "nsuri": "http://www.codexis.com/20210331",
     "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 [Member]"
       }
      }
     },
     "localname": "TermLoanMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "TransactionsWithAstraZenecaPLCMember",
     "nsuri": "http://www.codexis.com/20210331",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "country_US": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "UNITED STATES",
        "terseLabel": "United States [Member]"
       }
      }
     },
     "localname": "US",
     "nsuri": "http://xbrl.sec.gov/country/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "gYearItemType"
    },
    "dei_DocumentPeriodEndDate": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The end date of the period reflected on the cover page if a periodic report. For all other reports and registration statements containing historical data, it is the date up through which that historical data is presented.  If there is no historical data in the report, use the filing date. 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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "dateItemType"
    },
    "dei_DocumentQuarterlyReport": {
     "auth_ref": [
      "r440"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_DocumentTransitionReport": {
     "auth_ref": [
      "r441"
     ],
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "stateOrProvinceItemType"
    },
    "dei_EntityCentralIndexKey": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "yesNoItemType"
    },
    "dei_EntityEmergingGrowthCompany": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "fileNumberItemType"
    },
    "dei_EntityFilerCategory": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "edgarStateCountryItemType"
    },
    "dei_EntityInteractiveDataCurrent": {
     "auth_ref": [
      "r443"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "yesNoItemType"
    },
    "dei_EntityRegistrantName": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_EntityShellCompany": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_EntitySmallBusiness": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "booleanItemType"
    },
    "dei_EntityTaxIdentificationNumber": {
     "auth_ref": [
      "r442"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "employerIdItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "normalizedStringItemType"
    },
    "dei_Security12bTitle": {
     "auth_ref": [
      "r438"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "securityTitleItemType"
    },
    "dei_SecurityExchangeName": {
     "auth_ref": [
      "r439"
     ],
     "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/2020-01-31",
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CoverPage"
     ],
     "xbrltype": "tradingSymbolItemType"
    },
    "srt_AmericasMember": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Americas [Member]",
        "terseLabel": "Americas [Member]"
       }
      }
     },
     "localname": "AmericasMember",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ConsolidationItemsAxis": {
     "auth_ref": [
      "r145",
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r171",
      "r175"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Items [Axis]",
        "terseLabel": "Consolidation Items [Axis]"
       }
      }
     },
     "localname": "ConsolidationItemsAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_ConsolidationItemsDomain": {
     "auth_ref": [
      "r145",
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r171",
      "r175"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Items [Domain]",
        "terseLabel": "Consolidation Items [Domain]"
       }
      }
     },
     "localname": "ConsolidationItemsDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_CounterpartyNameAxis": {
     "auth_ref": [
      "r51",
      "r90"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparty Name [Axis]",
        "terseLabel": "Counterparty Name [Axis]"
       }
      }
     },
     "localname": "CounterpartyNameAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_DirectorMember": {
     "auth_ref": [
      "r184"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Director [Member]",
        "terseLabel": "Director [Member]"
       }
      }
     },
     "localname": "DirectorMember",
     "nsuri": "http://fasb.org/srt/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_MajorCustomersAxis": {
     "auth_ref": [
      "r182",
      "r273",
      "r279",
      "r416"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer [Axis]",
        "terseLabel": "Customer [Axis]"
       }
      }
     },
     "localname": "MajorCustomersAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_NameOfMajorCustomerDomain": {
     "auth_ref": [
      "r182",
      "r273",
      "r279",
      "r416"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer [Domain]",
        "terseLabel": "Customer [Domain]"
       }
      }
     },
     "localname": "NameOfMajorCustomerDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ProductOrServiceAxis": {
     "auth_ref": [
      "r178",
      "r273",
      "r277",
      "r380",
      "r413",
      "r414"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Product and Service [Axis]",
        "terseLabel": "Product and Service [Axis]"
       }
      }
     },
     "localname": "ProductOrServiceAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_ProductsAndServicesDomain": {
     "auth_ref": [
      "r178",
      "r273",
      "r277",
      "r380",
      "r413",
      "r414"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Product and Service [Domain]",
        "terseLabel": "Product and Service [Domain]"
       }
      }
     },
     "localname": "ProductsAndServicesDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_RealEstateAndAccumulatedDepreciationDescriptionOfPropertyAxis": {
     "auth_ref": [
      "r428",
      "r429",
      "r430",
      "r431",
      "r432",
      "r433",
      "r434",
      "r435"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Name of Property [Axis]",
        "terseLabel": "Name of Property [Axis]"
       }
      }
     },
     "localname": "RealEstateAndAccumulatedDepreciationDescriptionOfPropertyAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_RealEstateAndAccumulatedDepreciationNameOfPropertyDomain": {
     "auth_ref": [
      "r428",
      "r429",
      "r430",
      "r431",
      "r432",
      "r433",
      "r434",
      "r435"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Name of Property [Domain]",
        "terseLabel": "Name of Property [Domain]"
       }
      }
     },
     "localname": "RealEstateAndAccumulatedDepreciationNameOfPropertyDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_RepurchaseAgreementCounterpartyNameDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparty Name [Domain]",
        "terseLabel": "Counterparty Name [Domain]"
       }
      }
     },
     "localname": "RepurchaseAgreementCounterpartyNameDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScenarioForecastMember": {
     "auth_ref": [
      "r295"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forecast [Member]",
        "terseLabel": "Forecast [Member]"
       }
      }
     },
     "localname": "ScenarioForecastMember",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScenarioUnspecifiedDomain": {
     "auth_ref": [
      "r295"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Scenario [Domain]",
        "terseLabel": "Scenario [Domain]"
       }
      }
     },
     "localname": "ScenarioUnspecifiedDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis": {
     "auth_ref": [
      "r201"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment, Name [Axis]",
        "terseLabel": "Investment, Name [Axis]"
       }
      }
     },
     "localname": "ScheduleOfEquityMethodInvestmentEquityMethodInvesteeNameAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_SegmentGeographicalDomain": {
     "auth_ref": [
      "r179",
      "r180",
      "r273",
      "r278",
      "r415",
      "r428",
      "r429",
      "r430",
      "r431",
      "r432",
      "r433",
      "r434",
      "r435"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical [Domain]",
        "terseLabel": "Geographical [Domain]"
       }
      }
     },
     "localname": "SegmentGeographicalDomain",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "srt_StatementGeographicalAxis": {
     "auth_ref": [
      "r179",
      "r180",
      "r273",
      "r278",
      "r415",
      "r426",
      "r428",
      "r429",
      "r430",
      "r431",
      "r432",
      "r433",
      "r434",
      "r435",
      "r436"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical [Axis]",
        "terseLabel": "Geographical [Axis]",
        "verboseLabel": "Geographical [Axis]"
       }
      }
     },
     "localname": "StatementGeographicalAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationRevenuesbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_StatementScenarioAxis": {
     "auth_ref": [
      "r240",
      "r295",
      "r375"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Scenario [Axis]",
        "terseLabel": "Scenario [Axis]"
       }
      }
     },
     "localname": "StatementScenarioAxis",
     "nsuri": "http://fasb.org/srt/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "srt_TitleOfIndividualAxis": {
     "auth_ref": [
      "r184",
      "r369"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Title of Individual [Axis]",
        "terseLabel": "Title of Individual [Axis]"
       }
      }
     },
     "localname": "TitleOfIndividualAxis",
     "nsuri": "http://fasb.org/srt/2020-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/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_AccountsNotesAndLoansReceivableNetCurrent": {
     "auth_ref": [
      "r4",
      "r19",
      "r45",
      "r185",
      "r186",
      "r399"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 5.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsPayableCurrent": {
     "auth_ref": [
      "r35"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsReceivableGrossCurrent": {
     "auth_ref": [
      "r185",
      "r186"
     ],
     "calculation": {
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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 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",
        "totalLabel": "Total balance"
       }
      }
     },
     "localname": "AccountsReceivableGrossCurrent",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccountsReceivableMember": {
     "auth_ref": [],
     "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 [Member]"
       }
      }
     },
     "localname": "AccountsReceivableMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_AccountsReceivableRelatedParties": {
     "auth_ref": [
      "r18",
      "r88",
      "r367",
      "r370",
      "r405"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccruedLiabilitiesCurrent": {
     "auth_ref": [
      "r38"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccruedProfessionalFeesCurrentAndNoncurrent": {
     "auth_ref": [
      "r392",
      "r409"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment": {
     "auth_ref": [
      "r33",
      "r227"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdditionalPaidInCapital": {
     "auth_ref": [
      "r20",
      "r313"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 3.0,
       "parentTag": "us-gaap_StockholdersEquity",
       "weight": 1.0
      }
     },
     "crdr": "credit",
     "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. Includes adjustments to additional paid in capital. Some examples of such adjustments include recording the issuance of debt with a beneficial conversion feature and certain tax consequences of equity instruments awarded to employees. Use this element for the aggregate amount of additional paid-in capital associated with common and preferred stock. For additional paid-in capital associated with only common stock, use the element additional paid in capital, common stock. For additional paid-in capital associated with only preferred stock, use the element additional paid in capital, preferred stock.",
        "label": "Additional Paid in Capital",
        "verboseLabel": "Additional paid-in capital"
       }
      }
     },
     "localname": "AdditionalPaidInCapital",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdditionalPaidInCapitalMember": {
     "auth_ref": [
      "r93",
      "r94",
      "r95",
      "r310",
      "r311",
      "r312"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "AdditionalPaidInCapitalMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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 share settlement of equity awards"
       }
      }
     },
     "localname": "AdjustmentsRelatedToTaxWithholdingForShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdjustmentsToAdditionalPaidInCapitalShareBasedCompensationStockOptionsRequisiteServicePeriodRecognition": {
     "auth_ref": [],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase to additional paid-in capital (APIC) for recognition of cost for option under share-based payment arrangement.",
        "label": "APIC, Share-based Payment Arrangement, Option, Increase for Cost Recognition",
        "terseLabel": "Employee stock-based compensation"
       }
      }
     },
     "localname": "AdjustmentsToAdditionalPaidInCapitalShareBasedCompensationStockOptionsRequisiteServicePeriodRecognition",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AdjustmentsToAdditionalPaidInCapitalSharebasedCompensationRequisiteServicePeriodRecognitionValue": {
     "auth_ref": [
      "r296",
      "r298",
      "r315",
      "r316"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AllowanceForCreditLossesOnFinancingReceivablesTableTextBlock": {
     "auth_ref": [
      "r187",
      "r207"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_AllowanceForNotesAndLoansReceivableCurrent": {
     "auth_ref": [
      "r25",
      "r188",
      "r204"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesAnalysisofAllowanceforCreditLossesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount": {
     "auth_ref": [
      "r115"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareAmount",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_AntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareByAntidilutiveSecuritiesAxis": {
     "auth_ref": [
      "r115"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AntidilutiveSecuritiesNameDomain": {
     "auth_ref": [
      "r115"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "areaItemType"
    },
    "us-gaap_AssetRetirementObligation": {
     "auth_ref": [
      "r232"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AssetRetirementObligationAccretionExpense": {
     "auth_ref": [
      "r231",
      "r233"
     ],
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of accretion expense recognized during the period that is associated with an asset retirement obligation. Accretion expense measures and incorporates changes due to the passage of time into the carrying amount of the liability.",
        "label": "Asset Retirement Obligation, Accretion Expense",
        "terseLabel": "Accretion expense related to asset retirement obligation"
       }
      }
     },
     "localname": "AssetRetirementObligationAccretionExpense",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "AssetUnderConstructionMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Assets": {
     "auth_ref": [
      "r86",
      "r153",
      "r166",
      "r173",
      "r202",
      "r325",
      "r327",
      "r337",
      "r388",
      "r400"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AssetsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets [Abstract]",
        "verboseLabel": "Assets"
       }
      }
     },
     "localname": "AssetsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AssetsCurrent": {
     "auth_ref": [
      "r5",
      "r6",
      "r50",
      "r86",
      "r202",
      "r325",
      "r327",
      "r337"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_AssetsFairValueDisclosure": {
     "auth_ref": [
      "r329"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis": {
     "auth_ref": [
      "r193",
      "r217"
     ],
     "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": "Adjusted Cost and Carrying Value"
       }
      }
     },
     "localname": "AvailableForSaleDebtSecuritiesAmortizedCostBasis",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleDebtSecuritiesGrossUnrealizedLoss": {
     "auth_ref": [
      "r195"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue": {
     "auth_ref": [
      "r196",
      "r197",
      "r398"
     ],
     "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": "Fair Value"
       }
      }
     },
     "localname": "AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AvailableForSaleSecuritiesDebtSecurities": {
     "auth_ref": [
      "r192",
      "r194",
      "r217",
      "r391"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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"
       }
      }
     },
     "localname": "AvailableForSaleSecuritiesDebtSecurities",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_AwardTypeAxis": {
     "auth_ref": [
      "r299",
      "r308"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CapitalExpendituresIncurredButNotYetPaid": {
     "auth_ref": [
      "r79",
      "r80",
      "r81"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CapitalLeaseObligationsIncurred": {
     "auth_ref": [
      "r79",
      "r80"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CapitalizedContractCostNetCurrent": {
     "auth_ref": [
      "r221"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CapitalizedCostsOfUnprovedPropertiesExcludedFromAmortizationByPropertyOrProjectAxis": {
     "auth_ref": [
      "r381",
      "r382",
      "r383"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by project.",
        "label": "Project [Axis]",
        "terseLabel": "Project [Axis]"
       }
      }
     },
     "localname": "CapitalizedCostsOfUnprovedPropertiesExcludedFromAmortizationByPropertyOrProjectAxis",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CashAndCashEquivalentsAtCarryingValue": {
     "auth_ref": [
      "r2",
      "r31",
      "r77"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 2.0,
       "parentTag": "us-gaap_AssetsCurrent",
       "weight": 1.0
      },
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents": {
     "auth_ref": [
      "r69",
      "r77",
      "r82"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect": {
     "auth_ref": [
      "r69",
      "r338"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CashMember": {
     "auth_ref": [
      "r10"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "CashMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ClassOfStockDomain": {
     "auth_ref": [
      "r84",
      "r86",
      "r108",
      "r109",
      "r110",
      "r112",
      "r114",
      "r122",
      "r123",
      "r124",
      "r202",
      "r337"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_CommitmentsAndContingencies": {
     "auth_ref": [
      "r42",
      "r239",
      "r393",
      "r408"
     ],
     "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 11)"
       }
      }
     },
     "localname": "CommitmentsAndContingencies",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_CommitmentsAndContingenciesDisclosureTextBlock": {
     "auth_ref": [
      "r236",
      "r237",
      "r238",
      "r246"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingencies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CommonStockCapitalSharesReservedForFutureIssuance": {
     "auth_ref": [
      "r43"
     ],
     "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"
       }
      }
     },
     "localname": "CommonStockCapitalSharesReservedForFutureIssuance",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockMember": {
     "auth_ref": [
      "r93",
      "r94"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Stock that is subordinate to all other stock of the issuer.",
        "label": "Common Stock [Member]",
        "terseLabel": "Common Stock [Member]"
       }
      }
     },
     "localname": "CommonStockMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CommonStockParOrStatedValuePerShare": {
     "auth_ref": [
      "r17"
     ],
     "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 (usd per share)"
       }
      }
     },
     "localname": "CommonStockParOrStatedValuePerShare",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_CommonStockSharesAuthorized": {
     "auth_ref": [
      "r17"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "CommonStockSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockSharesIssued": {
     "auth_ref": [
      "r17"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "CommonStockSharesIssued",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockSharesOutstanding": {
     "auth_ref": [
      "r17",
      "r252"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "CommonStockSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_CommonStockValue": {
     "auth_ref": [
      "r17"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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,488 shares and 64,283 shares issued and outstanding at March\u00a031, 2021 and December\u00a031, 2020, respectively"
       }
      }
     },
     "localname": "CommonStockValue",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "ComputerEquipmentMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ConcentrationRiskBenchmarkDomain": {
     "auth_ref": [
      "r133",
      "r134",
      "r182",
      "r334",
      "r335"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ConcentrationRiskByBenchmarkAxis": {
     "auth_ref": [
      "r133",
      "r134",
      "r182",
      "r334",
      "r335",
      "r422"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskByTypeAxis": {
     "auth_ref": [
      "r133",
      "r134",
      "r182",
      "r334",
      "r335",
      "r422"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails",
      "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskPercentage1": {
     "auth_ref": [
      "r133",
      "r134",
      "r182",
      "r334",
      "r335"
     ],
     "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, percentage"
       }
      }
     },
     "localname": "ConcentrationRiskPercentage1",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_ConcentrationRiskTable": {
     "auth_ref": [
      "r130",
      "r133",
      "r134",
      "r135",
      "r334",
      "r336"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ConcentrationRiskTypeDomain": {
     "auth_ref": [
      "r133",
      "r134",
      "r182",
      "r334",
      "r335"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails",
      "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 [Member]"
       }
      }
     },
     "localname": "ConstructionInProgressMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ContractWithCustomerAssetAndLiabilityTableTextBlock": {
     "auth_ref": [
      "r261"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ContractWithCustomerAssetCreditLossExpense": {
     "auth_ref": [
      "r206",
      "r259",
      "r272"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerAssetGrossCurrent": {
     "auth_ref": [
      "r255",
      "r257"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 3.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiability": {
     "auth_ref": [
      "r255",
      "r256",
      "r274"
     ],
     "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",
        "verboseLabel": "Contract liabilities: deferred revenue"
       }
      }
     },
     "localname": "ContractWithCustomerLiability",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityChangeInTimeframePerformanceObligationSatisfiedRevenueRecognized": {
     "auth_ref": [
      "r260"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInEstimateOfTransactionPrice": {
     "auth_ref": [
      "r258"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInMeasureOfProgress": {
     "auth_ref": [
      "r258"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of increase (decrease) in revenue recognized for cumulative catch-up adjustment from change in measure of progress which (increases) decreases obligation to transfer good or service to customer for which consideration from customer has been received or is due.",
        "label": "Contract with Customer, Liability, Cumulative Catch-up Adjustment to Revenue, Change in Measure of Progress",
        "terseLabel": "Cumulative catch-up adjustment to revenue, change in measure of progress"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityCumulativeCatchUpAdjustmentToRevenueChangeInMeasureOfProgress",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityCurrent": {
     "auth_ref": [
      "r255",
      "r256",
      "r274"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityNoncurrent": {
     "auth_ref": [
      "r255",
      "r256",
      "r274"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ContractWithCustomerLiabilityRevenueRecognized": {
     "auth_ref": [
      "r275"
     ],
     "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",
        "terseLabel": "Revenue recognized"
       }
      }
     },
     "localname": "ContractWithCustomerLiabilityRevenueRecognized",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionRevenueRecognizedDuringPeriodDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ConvertibleDebtMember": {
     "auth_ref": [
      "r251"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "ConvertibleDebtMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CorporateNonSegmentMember": {
     "auth_ref": [
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r175",
      "r177"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "CorporateNonSegmentMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CostOfGoodsAndServicesSold": {
     "auth_ref": [
      "r58",
      "r380"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 3.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CostsAndExpenses": {
     "auth_ref": [
      "r56"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_CreditAvailabilityConcentrationRiskMember": {
     "auth_ref": [
      "r131"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Reflects the percentage that borrowing or credit line availability under commitments from one or more lenders is to a selected benchmark, such as total debt, segment debt. Risk is the materially adverse effects that funds which may be needed for operations or for a specific purpose will not be available on terms that are acceptable to an entity, if at all.",
        "label": "Credit Availability Concentration Risk [Member]",
        "terseLabel": "Credit Availability Concentration Risk [Member]"
       }
      }
     },
     "localname": "CreditAvailabilityConcentrationRiskMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_CreditLossFinancialInstrumentTextBlock": {
     "auth_ref": [
      "r205",
      "r209",
      "r210",
      "r212",
      "r213",
      "r218",
      "r219"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLosses"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_CustomerConcentrationRiskMember": {
     "auth_ref": [
      "r131",
      "r182"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "CustomerConcentrationRiskMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationConcentrationRiskDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_DebtInstrumentInterestRateStatedPercentage": {
     "auth_ref": [
      "r40"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_DebtSecuritiesAvailableForSaleAllowanceForCreditLossWriteoff": {
     "auth_ref": [
      "r220"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_DebtSecuritiesAvailableForSaleTableTextBlock": {
     "auth_ref": [
      "r198"
     ],
     "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/2020-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 [Member]"
       }
      }
     },
     "localname": "DemandDepositsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Depreciation": {
     "auth_ref": [
      "r75",
      "r225"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 8.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",
        "verboseLabel": "Depreciation"
       }
      }
     },
     "localname": "Depreciation",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows",
      "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_DisaggregationOfRevenueTable": {
     "auth_ref": [
      "r273",
      "r277",
      "r278",
      "r279",
      "r280",
      "r281",
      "r282",
      "r283"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionDisaggregationofRevenueDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_DisaggregationOfRevenueTableTextBlock": {
     "auth_ref": [
      "r273"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_DisclosureOfCompensationRelatedCostsShareBasedPaymentsTextBlock": {
     "auth_ref": [
      "r317"
     ],
     "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/2020-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/2020-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 [Member]"
       }
      }
     },
     "localname": "EMEAMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_EarningsPerShareBasic": {
     "auth_ref": [
      "r55",
      "r98",
      "r99",
      "r100",
      "r101",
      "r102",
      "r106",
      "r108",
      "r112",
      "r113",
      "r114",
      "r118",
      "r119",
      "r395",
      "r411"
     ],
     "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 (usd per share)"
       }
      }
     },
     "localname": "EarningsPerShareBasic",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_EarningsPerShareDiluted": {
     "auth_ref": [
      "r55",
      "r98",
      "r99",
      "r100",
      "r101",
      "r102",
      "r108",
      "r112",
      "r113",
      "r114",
      "r118",
      "r119",
      "r395",
      "r411"
     ],
     "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 (usd per share)"
       }
      }
     },
     "localname": "EarningsPerShareDiluted",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_EarningsPerShareTextBlock": {
     "auth_ref": [
      "r115",
      "r116",
      "r117",
      "r120"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for earnings per share.",
        "label": "Earnings Per Share [Text Block]",
        "terseLabel": "Net Loss per Share"
       }
      }
     },
     "localname": "EarningsPerShareTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShare"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_EmployeeRelatedLiabilitiesCurrent": {
     "auth_ref": [
      "r38"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedShareBasedAwardsOtherThanOptions": {
     "auth_ref": [
      "r307"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeServiceShareBasedCompensationNonvestedAwardsTotalCompensationCostNotYetRecognizedStockOptions": {
     "auth_ref": [
      "r307"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EmployeeStockOptionMember": {
     "auth_ref": [
      "r305"
     ],
     "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]",
        "verboseLabel": "Stock Options [Member]"
       }
      }
     },
     "localname": "EmployeeStockOptionMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_EquityComponentDomain": {
     "auth_ref": [
      "r93",
      "r94",
      "r95",
      "r97",
      "r103",
      "r105",
      "r121",
      "r203",
      "r252",
      "r253",
      "r310",
      "r311",
      "r312",
      "r320",
      "r321",
      "r339",
      "r340",
      "r341",
      "r342",
      "r343",
      "r344",
      "r417",
      "r418",
      "r419"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueAmount": {
     "auth_ref": [
      "r199"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_EquitySecuritiesWithoutReadilyDeterminableFairValueTableTextBlock": {
     "auth_ref": [
      "r200"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueAssetsAndLiabilitiesMeasuredOnRecurringAndNonrecurringBasisTable": {
     "auth_ref": [
      "r329",
      "r330",
      "r331",
      "r332"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueAssetsMeasuredOnRecurringBasisTextBlock": {
     "auth_ref": [
      "r329",
      "r330"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_FairValueByFairValueHierarchyLevelAxis": {
     "auth_ref": [
      "r286",
      "r287",
      "r288",
      "r289",
      "r290",
      "r291",
      "r292",
      "r294",
      "r330",
      "r377",
      "r378",
      "r379"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_FairValueInputsLevel1Member": {
     "auth_ref": [
      "r286",
      "r287",
      "r292",
      "r294",
      "r330",
      "r377"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "FairValueInputsLevel1Member",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FairValueInputsLevel3Member": {
     "auth_ref": [
      "r286",
      "r287",
      "r288",
      "r289",
      "r290",
      "r291",
      "r292",
      "r294",
      "r330",
      "r379"
     ],
     "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 3 [Member]"
       }
      }
     },
     "localname": "FairValueInputsLevel3Member",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FairValueMeasurementInputsDisclosureTextBlock": {
     "auth_ref": [
      "r333"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurements"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_FairValueMeasurementsFairValueHierarchyDomain": {
     "auth_ref": [
      "r286",
      "r287",
      "r288",
      "r289",
      "r290",
      "r291",
      "r292",
      "r294",
      "r377",
      "r378",
      "r379"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinanceLeaseLiabilityMaturityTableTextBlock": {
     "auth_ref": [
      "r361"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Tabular disclosure of undiscounted cash flows of finance lease liability. Includes, but is not limited to, reconciliation of undiscounted cash flows to finance lease liability recognized in statement of financial position.",
        "label": "Finance Lease, Liability, Fiscal Year Maturity [Table Text Block]",
        "terseLabel": "Finance lease liability"
       }
      }
     },
     "localname": "FinanceLeaseLiabilityMaturityTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_FinanceLeasePrincipalPayments": {
     "auth_ref": [
      "r349",
      "r357"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 2.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": "Finance Lease, Principal Payments"
       }
      }
     },
     "localname": "FinanceLeasePrincipalPayments",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesCashPaidforLeaseObligationsDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinanceLeaseRightOfUseAsset": {
     "auth_ref": [
      "r346"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinanceLeaseRightOfUseAssetAmortization": {
     "auth_ref": [
      "r348",
      "r353",
      "r362"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 4.0,
       "parentTag": "us-gaap_LeaseCost",
       "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": "Finance lease amortization of right-of-use assets"
       }
      }
     },
     "localname": "FinanceLeaseRightOfUseAssetAmortization",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "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/2020-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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivableRecordedInvestmentCurrent": {
     "auth_ref": [
      "r190",
      "r208",
      "r216"
     ],
     "calculation": {
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails": {
       "order": 2.0,
       "parentTag": "us-gaap_AccountsReceivableGrossCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of financing receivable not past due.",
        "label": "Financing Receivable, Not Past Due",
        "terseLabel": "Current"
       }
      }
     },
     "localname": "FinancingReceivableRecordedInvestmentCurrent",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinancingReceivableRecordedInvestmentPastDue": {
     "auth_ref": [
      "r190",
      "r208",
      "r216"
     ],
     "calculation": {
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails": {
       "order": 1.0,
       "parentTag": "us-gaap_AccountsReceivableGrossCurrent",
       "weight": 1.0
      }
     },
     "crdr": "debit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of financing receivable past due.",
        "label": "Financing Receivable, Past Due",
        "terseLabel": "Past due"
       }
      }
     },
     "localname": "FinancingReceivableRecordedInvestmentPastDue",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_FinancingReceivables30To59DaysPastDueMember": {
     "auth_ref": [
      "r216"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "FinancingReceivables30To59DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivables60To89DaysPastDueMember": {
     "auth_ref": [
      "r216"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "FinancingReceivables60To89DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivablesEqualToGreaterThan90DaysPastDueMember": {
     "auth_ref": [
      "r216"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "FinancingReceivablesEqualToGreaterThan90DaysPastDueMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_FinancingReceivablesPeriodPastDueAxis": {
     "auth_ref": [
      "r208",
      "r216"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by time period financial asset is past due.",
        "label": "Financial Asset, Period Past Due [Axis]",
        "terseLabel": "Financial Asset, Period Past Due [Axis]"
       }
      }
     },
     "localname": "FinancingReceivablesPeriodPastDueAxis",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_FinancingReceivablesPeriodPastDueDomain": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Period in which financial asset is 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, Period Past Due [Domain]",
        "terseLabel": "Financial Asset, Period Past Due [Domain]"
       }
      }
     },
     "localname": "FinancingReceivablesPeriodPastDueDomain",
     "nsuri": "http://fasb.org/us-gaap/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_GeographicDistributionAxis": {
     "auth_ref": [
      "r214",
      "r396",
      "r397"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_GeographicDistributionDomain": {
     "auth_ref": [
      "r396",
      "r397"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_Goodwill": {
     "auth_ref": [
      "r222",
      "r223",
      "r387"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsGoodwillDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationGoodwillDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments": {
     "auth_ref": [
      "r91",
      "r153",
      "r165",
      "r169",
      "r172",
      "r175"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 1.0,
       "parentTag": "us-gaap_NetIncomeLoss",
       "weight": 1.0
      }
     },
     "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",
        "totalLabel": "Loss before income taxes",
        "verboseLabel": "Income (loss) before income taxes"
       }
      }
     },
     "localname": "IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncomeStatementLocationAxis": {
     "auth_ref": [
      "r229"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncomeStatementLocationDomain": {
     "auth_ref": [],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_IncomeTaxExpenseBenefit": {
     "auth_ref": [
      "r87",
      "r104",
      "r105",
      "r151",
      "r319",
      "r322",
      "r323",
      "r412"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInAccountsPayable": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 4.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInContractWithCustomerLiability": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 6.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInFinanceReceivables": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInInventories": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 12.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IncreaseDecreaseInOtherNoncurrentLiabilities": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 7.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_IndemnificationGuaranteeMember": {
     "auth_ref": [
      "r247",
      "r250"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "IndemnificationGuaranteeMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_InterestPaidNet": {
     "auth_ref": [
      "r68",
      "r71",
      "r78"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryFinishedGoods": {
     "auth_ref": [
      "r46"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryNet": {
     "auth_ref": [
      "r3",
      "r49"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_InventoryRawMaterials": {
     "auth_ref": [
      "r48"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InventoryWorkInProcess": {
     "auth_ref": [
      "r47"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsInventoriesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeAmortizationOfDiscount": {
     "auth_ref": [
      "r61"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeAmortizationOfPremium": {
     "auth_ref": [
      "r61"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentIncomeInterest": {
     "auth_ref": [
      "r60",
      "r146"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 2.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments",
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_InvestmentOwnedBalanceShares": {
     "auth_ref": [
      "r423",
      "r425"
     ],
     "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"
       }
      }
     },
     "localname": "InvestmentOwnedBalanceShares",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_InvestmentsAndOtherNoncurrentAssets": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 2.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecurities"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LeaseCost": {
     "auth_ref": [
      "r360",
      "r362"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LeaseCostTableTextBlock": {
     "auth_ref": [
      "r360"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LeaseholdImprovementsGross": {
     "auth_ref": [
      "r8",
      "r226"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LeaseholdImprovementsMember": {
     "auth_ref": [
      "r226"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Additions or improvements to assets held under a lease arrangement.",
        "label": "Leasehold Improvements [Member]",
        "terseLabel": "Leasehold improvements [Member]"
       }
      }
     },
     "localname": "LeaseholdImprovementsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_LeaseholdsAndLeaseholdImprovementsMember": {
     "auth_ref": [
      "r226"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "LeaseholdsAndLeaseholdImprovementsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_LesseeFinanceLeaseTermOfContract1": {
     "auth_ref": [
      "r351"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedDiscountRate": {
     "auth_ref": [
      "r352"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedRenewalTerm1": {
     "auth_ref": [
      "r352"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLeaseNotYetCommencedTermOfContract1": {
     "auth_ref": [
      "r352"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityMaturityTableTextBlock": {
     "auth_ref": [
      "r361"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue": {
     "auth_ref": [
      "r361"
     ],
     "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",
        "totalLabel": "Total minimum lease payments"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsDue",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths": {
     "auth_ref": [
      "r361"
     ],
     "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 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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour": {
     "auth_ref": [
      "r361"
     ],
     "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 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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree": {
     "auth_ref": [
      "r361"
     ],
     "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 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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo": {
     "auth_ref": [
      "r361"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear": {
     "auth_ref": [
      "r361"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails": {
       "order": 6.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 9 months)"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount": {
     "auth_ref": [
      "r361"
     ],
     "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",
        "negatedTerseLabel": "Less: imputed interest"
       }
      }
     },
     "localname": "LesseeOperatingLeaseLiabilityUndiscountedExcessAmount",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LesseeOperatingLeaseRenewalTerm": {
     "auth_ref": [
      "r351"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_Liabilities": {
     "auth_ref": [
      "r37",
      "r86",
      "r167",
      "r202",
      "r326",
      "r327",
      "r328",
      "r337"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 2.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LiabilitiesAndStockholdersEquity": {
     "auth_ref": [
      "r24",
      "r86",
      "r202",
      "r337",
      "r390",
      "r404"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LiabilitiesCurrent": {
     "auth_ref": [
      "r39",
      "r86",
      "r202",
      "r326",
      "r327",
      "r328",
      "r337"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LineOfCreditFacilityMaximumBorrowingCapacity": {
     "auth_ref": [
      "r36"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LossContingenciesByNatureOfContingencyAxis": {
     "auth_ref": [
      "r239",
      "r240",
      "r241",
      "r242",
      "r243",
      "r244",
      "r245",
      "r248",
      "r249"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_LossContingencyAccrualCarryingValueCurrent": {
     "auth_ref": [
      "r239"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_LossContingencyNatureDomain": {
     "auth_ref": [
      "r239",
      "r240",
      "r241",
      "r242",
      "r243",
      "r244",
      "r245",
      "r248",
      "r249"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_MoneyMarketFundsMember": {
     "auth_ref": [
      "r286"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "MoneyMarketFundsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_NatureOfOperations": {
     "auth_ref": [
      "r125",
      "r139"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusiness"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_NetCashProvidedByUsedInFinancingActivities": {
     "auth_ref": [
      "r69"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetCashProvidedByUsedInInvestingActivities": {
     "auth_ref": [
      "r69"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetCashProvidedByUsedInOperatingActivities": {
     "auth_ref": [
      "r69",
      "r73",
      "r76"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_NetIncomeLoss": {
     "auth_ref": [
      "r1",
      "r52",
      "r53",
      "r54",
      "r76",
      "r86",
      "r96",
      "r98",
      "r99",
      "r100",
      "r101",
      "r104",
      "r105",
      "r111",
      "r153",
      "r165",
      "r169",
      "r172",
      "r175",
      "r202",
      "r337",
      "r394",
      "r410"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 2.0,
       "parentTag": "us-gaap_NetCashProvidedByUsedInOperatingActivities",
       "weight": 1.0
      },
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "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",
        "netLabel": "Net income (loss)",
        "terseLabel": "Net loss",
        "totalLabel": "Net loss"
       }
      }
     },
     "localname": "NetIncomeLoss",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_NoncashOrPartNoncashAcquisitionNoncashFinancialOrEquityInstrumentConsiderationSharesIssued1": {
     "auth_ref": [
      "r79",
      "r80",
      "r81"
     ],
     "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"
       }
      }
     },
     "localname": "NoncashOrPartNoncashAcquisitionNoncashFinancialOrEquityInstrumentConsiderationSharesIssued1",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_NoncurrentAssets": {
     "auth_ref": [
      "r180"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationLongLivedAssetsbyGeographicAreaDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NonmonetaryTransactionGrossOperatingRevenueRecognized": {
     "auth_ref": [
      "r363"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NotesReceivableGross": {
     "auth_ref": [
      "r211",
      "r215",
      "r216"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 2.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_NumberOfOperatingSegments": {
     "auth_ref": [
      "r141"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTextualDetails"
     ],
     "xbrltype": "integerItemType"
    },
    "us-gaap_NumberOfReportableSegments": {
     "auth_ref": [
      "r141"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTextualDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OperatingIncomeLoss": {
     "auth_ref": [
      "r153",
      "r165",
      "r169",
      "r172",
      "r175"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 1.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments",
       "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": "Loss from operations",
        "verboseLabel": "Income (loss) from operations"
       }
      }
     },
     "localname": "OperatingIncomeLoss",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseCost": {
     "auth_ref": [
      "r354",
      "r362"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 1.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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OperatingLeaseLiability": {
     "auth_ref": [
      "r347"
     ],
     "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": "Operating Lease, Liability"
       }
      }
     },
     "localname": "OperatingLeaseLiability",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesMaturityAnalysisofOperatingLeaseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseLiabilityCurrent": {
     "auth_ref": [
      "r347"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseLiabilityNoncurrent": {
     "auth_ref": [
      "r347"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeasePayments": {
     "auth_ref": [
      "r350",
      "r357"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesCashPaidforLeaseObligationsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseRightOfUseAsset": {
     "auth_ref": [
      "r346"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseRightOfUseAssetAmortizationExpense": {
     "auth_ref": [
      "r75"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OperatingLeaseWeightedAverageDiscountRatePercent": {
     "auth_ref": [
      "r359",
      "r362"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherLeaseInformationDetails"
     ],
     "xbrltype": "percentItemType"
    },
    "us-gaap_OperatingLeaseWeightedAverageRemainingLeaseTerm1": {
     "auth_ref": [
      "r358",
      "r362"
     ],
     "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 (in years)"
       }
      }
     },
     "localname": "OperatingLeaseWeightedAverageRemainingLeaseTerm1",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherLeaseInformationDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_OperatingSegmentsMember": {
     "auth_ref": [
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r175"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "OperatingSegmentsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_OtherAccruedLiabilitiesCurrentAndNoncurrent": {
     "auth_ref": [
      "r392",
      "r409"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherAssetsNoncurrent": {
     "auth_ref": [
      "r34"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesEstimatedMaturityAnalysisDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_OtherLiabilitiesNoncurrent": {
     "auth_ref": [
      "r41"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherNoncashIncome": {
     "auth_ref": [
      "r76"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 5.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherNonoperatingIncomeExpense": {
     "auth_ref": [
      "r62"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 3.0,
       "parentTag": "us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesMinorityInterestAndIncomeLossFromEquityMethodInvestments",
       "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 expenses, net"
       }
      }
     },
     "localname": "OtherNonoperatingIncomeExpense",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_OtherOperatingActivitiesCashFlowStatement": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PastDueFinancingReceivablesTableTextBlock": {
     "auth_ref": [
      "r189",
      "r190",
      "r208",
      "r216"
     ],
     "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"
       }
      }
     },
     "localname": "PastDueFinancingReceivablesTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_PaymentsForRent": {
     "auth_ref": [
      "r72"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation": {
     "auth_ref": [
      "r67"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 3.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsToAcquireOtherInvestments": {
     "auth_ref": [
      "r65"
     ],
     "crdr": "credit",
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Amount of cash outflow to acquire investments classified as other.",
        "label": "Payments to Acquire Other Investments",
        "terseLabel": "Payments to acquire other investments"
       }
      }
     },
     "localname": "PaymentsToAcquireOtherInvestments",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PaymentsToAcquirePropertyPlantAndEquipment": {
     "auth_ref": [
      "r64"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "PerformanceSharesMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PlanNameAxis": {
     "auth_ref": [
      "r299",
      "r308"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails",
      "http://www.codexis.com/role/StockbasedCompensationPSUsandPBOsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PreferredStockParOrStatedValuePerShare": {
     "auth_ref": [
      "r16"
     ],
     "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 (usd per share)"
       }
      }
     },
     "localname": "PreferredStockParOrStatedValuePerShare",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "perShareItemType"
    },
    "us-gaap_PreferredStockSharesAuthorized": {
     "auth_ref": [
      "r16"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "PreferredStockSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockSharesIssued": {
     "auth_ref": [
      "r16"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "PreferredStockSharesIssued",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockSharesOutstanding": {
     "auth_ref": [
      "r16"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "PreferredStockSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheetsParenthetical"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_PreferredStockValue": {
     "auth_ref": [
      "r16"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PrepaidExpenseAndOtherAssetsCurrent": {
     "auth_ref": [
      "r5",
      "r29",
      "r30"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 4.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromCollaborators": {
     "auth_ref": [
      "r70"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromSaleOfPropertyPlantAndEquipment": {
     "auth_ref": [
      "r63"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProceedsFromStockOptionsExercised": {
     "auth_ref": [
      "r66",
      "r309"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ProjectMember": {
     "auth_ref": [
      "r384"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Planned program of work.",
        "label": "Project [Domain]",
        "terseLabel": "Project [Domain]"
       }
      }
     },
     "localname": "ProjectMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentByTypeAxis": {
     "auth_ref": [
      "r33",
      "r228"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentGross": {
     "auth_ref": [
      "r32",
      "r226"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentNet": {
     "auth_ref": [
      "r11",
      "r12",
      "r228",
      "r406"
     ],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails": {
       "order": null,
       "parentTag": null,
       "root": true,
       "weight": null
      },
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentTextBlock": {
     "auth_ref": [
      "r11",
      "r228"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_PropertyPlantAndEquipmentTypeDomain": {
     "auth_ref": [
      "r11",
      "r226"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_PurchaseObligation": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/BalanceSheetsDetailsOtherAccruedLiabilitiesDetails": {
       "order": 2.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/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_ReconciliationOfRevenueFromSegmentsToConsolidatedTextBlock": {
     "auth_ref": [
      "r164",
      "r169"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_RelatedPartyTransactionAxis": {
     "auth_ref": [
      "r293",
      "r366",
      "r367",
      "r370"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RelatedPartyTransactionDomain": {
     "auth_ref": [
      "r293"
     ],
     "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/2020-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/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_RelatedPartyTransactionsDisclosureTextBlock": {
     "auth_ref": [
      "r364",
      "r365",
      "r367",
      "r371",
      "r372"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactions"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ResearchAndDevelopmentExpense": {
     "auth_ref": [
      "r318",
      "r437"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "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 [Member]"
       }
      }
     },
     "localname": "ResearchAndDevelopmentExpenseMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RestrictedCash": {
     "auth_ref": [
      "r82",
      "r386",
      "r402"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 6.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalents": {
     "auth_ref": [
      "r10",
      "r77",
      "r82",
      "r386",
      "r402"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalentsCashAndCashEquivalentsAxis": {
     "auth_ref": [
      "r31"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsCashandCashEquivalentsDetails",
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails",
      "http://www.codexis.com/role/FairValueMeasurementsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RestrictedCashAndCashEquivalentsNoncurrent": {
     "auth_ref": [
      "r7",
      "r13",
      "r77",
      "r82",
      "r427"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 3.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RestrictedCashAndInvestmentsNoncurrent": {
     "auth_ref": [],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "RestrictedStockUnitsRSUMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationRestrictedStockUnitsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_RetainedEarningsAccumulatedDeficit": {
     "auth_ref": [
      "r21",
      "r253",
      "r313",
      "r403",
      "r420",
      "r421"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RetainedEarningsMember": {
     "auth_ref": [
      "r93",
      "r94",
      "r95",
      "r97",
      "r103",
      "r105",
      "r203",
      "r310",
      "r311",
      "r312",
      "r320",
      "r321",
      "r417",
      "r419"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The cumulative amount of the reporting entity's undistributed earnings or deficit.",
        "label": "Retained Earnings [Member]",
        "terseLabel": "Accumulated Deficit [Member]"
       }
      }
     },
     "localname": "RetainedEarningsMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax": {
     "auth_ref": [
      "r144",
      "r145",
      "r164",
      "r170",
      "r171",
      "r178",
      "r179",
      "r182",
      "r271",
      "r273",
      "r380"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "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": [
      "r261",
      "r262",
      "r263",
      "r264",
      "r265",
      "r266",
      "r269",
      "r270",
      "r276",
      "r285"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognition"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_RevenueFromRelatedParties": {
     "auth_ref": [
      "r57",
      "r424"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueInitialApplicationPeriodCumulativeEffectTransitionTable": {
     "auth_ref": [
      "r284"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligation": {
     "auth_ref": [
      "r267"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionPeriod1": {
     "auth_ref": [
      "r268"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "durationItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionStartDateAxis": {
     "auth_ref": [
      "r268"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Start date of time band for expected timing of satisfaction of remaining performance obligation, in CCYY-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RevenueRecognitionPerformanceObligationDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_RevenueRemainingPerformanceObligationExpectedTimingOfSatisfactionTableTextBlock": {
     "auth_ref": [
      "r268"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "RevolvingCreditFacilityMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SalesRevenueProductLineMember": {
     "auth_ref": [
      "r132"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "SalesRevenueProductLineMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTable": {
     "auth_ref": [
      "r115"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock": {
     "auth_ref": [
      "r115"
     ],
     "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 Loss Per Share"
       }
      }
     },
     "localname": "ScheduleOfAntidilutiveSecuritiesExcludedFromComputationOfEarningsPerShareTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareTables"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfCollaborativeArrangementsAndNoncollaborativeArrangementTransactionsTable": {
     "auth_ref": [
      "r324"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTable": {
     "auth_ref": [
      "r298",
      "r306",
      "r314"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfEmployeeServiceShareBasedCompensationAllocationOfRecognizedPeriodCostsTextBlock": {
     "auth_ref": [
      "r298",
      "r306",
      "r314"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfEntityWideDisclosureOnGeographicAreasLongLivedAssetsInIndividualForeignCountriesByCountryTextBlock": {
     "auth_ref": [
      "r180"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfFinancingReceivableAllowanceForCreditLossesTable": {
     "auth_ref": [
      "r207"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/AllowanceforCreditLossesSummaryofFinanceReceivablesbyAgingCategoryDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock": {
     "auth_ref": [
      "r224"
     ],
     "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 intangible assets and goodwill"
       }
      }
     },
     "localname": "ScheduleOfIntangibleAssetsAndGoodwillTableTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfInventoryCurrentTableTextBlock": {
     "auth_ref": [
      "r9",
      "r26",
      "r27",
      "r28"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfPropertyPlantAndEquipmentTable": {
     "auth_ref": [
      "r33",
      "r228"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BalanceSheetsDetailsPropertyandEquipmentnetDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfRelatedPartyTransactionsByRelatedPartyTable": {
     "auth_ref": [
      "r89",
      "r368",
      "r370"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/RelatedPartyTransactionsAstraZenecaPLCDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_ScheduleOfSegmentReportingInformationBySegmentTable": {
     "auth_ref": [
      "r153",
      "r156",
      "r168",
      "r224"
     ],
     "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/2020-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": [
      "r153",
      "r156",
      "r168",
      "r224"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_ScheduleOfShareBasedCompensationArrangementsByShareBasedPaymentAwardTable": {
     "auth_ref": [
      "r299",
      "r308"
     ],
     "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/2020-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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SchedulesOfConcentrationOfRiskByRiskFactorTextBlock": {
     "auth_ref": [
      "r130",
      "r133",
      "r134",
      "r135",
      "r334",
      "r336"
     ],
     "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 customers that contributed 10% or more of total accounts receivable"
       }
      }
     },
     "localname": "SchedulesOfConcentrationOfRiskByRiskFactorTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SecurityOwnedNotReadilyMarketableAxis": {
     "auth_ref": [
      "r385"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SecurityOwnedNotReadilyMarketableNameDomain": {
     "auth_ref": [
      "r385"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/FairValueMeasurementsDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesCarryingValueandFairValueofSecuritiesDetails",
      "http://www.codexis.com/role/InvestmentsinNonMarketableSecuritiesTextualDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SegmentDomain": {
     "auth_ref": [
      "r140",
      "r144",
      "r145",
      "r146",
      "r147",
      "r148",
      "r149",
      "r150",
      "r151",
      "r152",
      "r153",
      "r154",
      "r155",
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r170",
      "r171",
      "r172",
      "r173",
      "r175",
      "r182",
      "r413"
     ],
     "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/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_SegmentReportingDisclosureTextBlock": {
     "auth_ref": [
      "r140",
      "r142",
      "r143",
      "r153",
      "r157",
      "r169",
      "r173",
      "r174",
      "r175",
      "r176",
      "r178",
      "r181",
      "r182",
      "r183"
     ],
     "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/2020-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/2020-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": [
      "r83",
      "r158",
      "r159",
      "r160",
      "r161",
      "r162",
      "r163",
      "r179"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SellingGeneralAndAdministrativeExpense": {
     "auth_ref": [
      "r59"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations": {
       "order": 2.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "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 [Member]"
       }
      }
     },
     "localname": "SellingGeneralAndAdministrativeExpensesMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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 [Member]"
       }
      }
     },
     "localname": "SeriesAPreferredStockMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_ShareBasedCompensation": {
     "auth_ref": [
      "r74"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows": {
       "order": 10.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows",
      "http://www.codexis.com/role/SegmentGeographicalandOtherRevenueInformationSegmentReportingDetails",
      "http://www.codexis.com/role/StockbasedCompensationStockbasedCompensationExpenseDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardAwardVestingPeriod1": {
     "auth_ref": [
      "r300"
     ],
     "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/2020-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/2020-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": [
      "r302"
     ],
     "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"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAuthorized",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant": {
     "auth_ref": [
      "r308"
     ],
     "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"
       }
      }
     },
     "localname": "ShareBasedCompensationArrangementByShareBasedPaymentAwardNumberOfSharesAvailableForGrant",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/StockbasedCompensationEquityIncentivePlansDetails"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShareBasedCompensationArrangementsByShareBasedPaymentAwardAwardTypeAndPlanNameDomain": {
     "auth_ref": [
      "r297",
      "r303"
     ],
     "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/2020-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/2020-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 [Member]"
       }
      }
     },
     "localname": "ShareBasedCompensationAwardTrancheOneMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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 [Member]"
       }
      }
     },
     "localname": "ShareBasedCompensationAwardTrancheTwoMember",
     "nsuri": "http://fasb.org/us-gaap/2020-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_SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage": {
     "auth_ref": [
      "r300"
     ],
     "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 (percent)"
       }
      }
     },
     "localname": "SharebasedCompensationArrangementBySharebasedPaymentAwardAwardVestingRightsPercentage",
     "nsuri": "http://fasb.org/us-gaap/2020-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": [
      "r301"
     ],
     "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/2020-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/2020-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": "Ending balance (shares)",
        "periodStartLabel": "Beginning balance (shares)"
       }
      }
     },
     "localname": "SharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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 share settlement of equity awards (shares)"
       }
      }
     },
     "localname": "SharesPaidForTaxWithholdingForShareBasedCompensation",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_ShortTermLeaseCost": {
     "auth_ref": [
      "r355",
      "r362"
     ],
     "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 short-term lease cost, excluding expense for lease with term of one month or less.",
        "label": "Short-term Lease, Cost",
        "terseLabel": "Short-term lease cost"
       }
      }
     },
     "localname": "ShortTermLeaseCost",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SignificantAccountingPoliciesTextBlock": {
     "auth_ref": [
      "r92"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SignificantSupplyCommitmentRemainingMinimumAmountCommitted": {
     "auth_ref": [
      "r42",
      "r393",
      "r407"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_StatementBusinessSegmentsAxis": {
     "auth_ref": [
      "r0",
      "r140",
      "r144",
      "r145",
      "r146",
      "r147",
      "r148",
      "r149",
      "r150",
      "r151",
      "r152",
      "r153",
      "r154",
      "r155",
      "r164",
      "r165",
      "r166",
      "r167",
      "r169",
      "r170",
      "r171",
      "r172",
      "r173",
      "r175",
      "r182",
      "r224",
      "r230",
      "r234",
      "r235",
      "r413"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by business segments.",
        "label": "Segments [Axis]",
        "terseLabel": "Segments [Axis]"
       }
      }
     },
     "localname": "StatementBusinessSegmentsAxis",
     "nsuri": "http://fasb.org/us-gaap/2020-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": [
      "r15",
      "r16",
      "r17",
      "r84",
      "r86",
      "r108",
      "r109",
      "r110",
      "r112",
      "r114",
      "r122",
      "r123",
      "r124",
      "r202",
      "r252",
      "r337"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/DescriptionofBusinessDetails",
      "http://www.codexis.com/role/RelatedPartyTransactionsMolecularAssembliesIncDetails",
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementEquityComponentsAxis": {
     "auth_ref": [
      "r44",
      "r93",
      "r94",
      "r95",
      "r97",
      "r103",
      "r105",
      "r121",
      "r203",
      "r252",
      "r253",
      "r310",
      "r311",
      "r312",
      "r320",
      "r321",
      "r339",
      "r340",
      "r341",
      "r342",
      "r343",
      "r344",
      "r417",
      "r418",
      "r419"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-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/2020-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/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_StatementTable": {
     "auth_ref": [
      "r93",
      "r94",
      "r95",
      "r121",
      "r380"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StockCompensationPlanMember": {
     "auth_ref": [
      "r115"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "StockCompensationPlanMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/NetLossperShareDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "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 (shares)"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodSharesOther",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_StockIssuedDuringPeriodSharesStockOptionsExercised": {
     "auth_ref": [
      "r16",
      "r17",
      "r252",
      "r253",
      "r304"
     ],
     "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 (shares)",
        "verboseLabel": "Exercise of stock options (shares)"
       }
      }
     },
     "localname": "StockIssuedDuringPeriodSharesStockOptionsExercised",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStockDetails",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_StockIssuedDuringPeriodValueStockOptionsExercised": {
     "auth_ref": [
      "r44",
      "r252",
      "r253"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_StockholdersEquity": {
     "auth_ref": [
      "r17",
      "r22",
      "r23",
      "r86",
      "r191",
      "r202",
      "r337"
     ],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 1.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": "Ending balance",
        "periodStartLabel": "Beginning balance",
        "totalLabel": "Total stockholders' equity"
       }
      }
     },
     "localname": "StockholdersEquity",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofStockholdersEquity"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_StockholdersEquityNoteDisclosureTextBlock": {
     "auth_ref": [
      "r85",
      "r253",
      "r254"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CapitalStock"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_SubleaseIncome": {
     "auth_ref": [
      "r356",
      "r362"
     ],
     "calculation": {
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails": {
       "order": 3.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesLeaseCostDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_SubsequentEventLineItems": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Detail information of subsequent event by type. User is expected to use existing line items from elsewhere in the taxonomy as the primary line items for this disclosure, which is further associated with dimension and member elements pertaining to a subsequent event.",
        "label": "Subsequent Event [Line Items]",
        "terseLabel": "Subsequent Event [Line Items]"
       }
      }
     },
     "localname": "SubsequentEventLineItems",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SubsequentEventMember": {
     "auth_ref": [
      "r345",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Identifies event that occurred after the balance sheet date but before financial statements are issued or available to be issued.",
        "label": "Subsequent Event [Member]",
        "terseLabel": "Subsequent Event [Member]"
       }
      }
     },
     "localname": "SubsequentEventMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SubsequentEventTable": {
     "auth_ref": [
      "r345",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Discloses pertinent information about one or more significant events or transactions that occurred after the balance sheet date through the date the financial statements were issued or the date the financial statements were available to be issued.",
        "label": "Subsequent Event [Table]",
        "terseLabel": "Subsequent Event [Table]"
       }
      }
     },
     "localname": "SubsequentEventTable",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SubsequentEventTypeAxis": {
     "auth_ref": [
      "r345",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Information by event that occurred after the balance sheet date but before financial statements are issued or available to be issued.",
        "label": "Subsequent Event Type [Axis]",
        "terseLabel": "Subsequent Event Type [Axis]"
       }
      }
     },
     "localname": "SubsequentEventTypeAxis",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SubsequentEventTypeDomain": {
     "auth_ref": [
      "r345",
      "r374"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Event that occurred after the balance sheet date but before financial statements are issued or available to be issued.",
        "label": "Subsequent Event Type [Domain]",
        "terseLabel": "Subsequent Event Type [Domain]"
       }
      }
     },
     "localname": "SubsequentEventTypeDomain",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEventDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SubsequentEventsAbstract": {
     "auth_ref": [],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subsequent Events [Abstract]",
        "terseLabel": "Subsequent Events [Abstract]"
       }
      }
     },
     "localname": "SubsequentEventsAbstract",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "xbrltype": "stringItemType"
    },
    "us-gaap_SubsequentEventsTextBlock": {
     "auth_ref": [
      "r373",
      "r376"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The entire disclosure for significant events or transactions that occurred after the balance sheet date through the date the financial statements were issued or the date the financial statements were available to be issued. Examples include: the sale of a capital stock issue, purchase of a business, settlement of litigation, catastrophic loss, significant foreign exchange rate changes, loans to insiders or affiliates, and transactions not in the ordinary course of business.",
        "label": "Subsequent Events [Text Block]",
        "terseLabel": "Subsequent Event"
       }
      }
     },
     "localname": "SubsequentEventsTextBlock",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/SubsequentEvent"
     ],
     "xbrltype": "textBlockItemType"
    },
    "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofCashFlows"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SupplyCommitmentArrangementMember": {
     "auth_ref": [
      "r14",
      "r389",
      "r401"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SupplyCommitmentAxis": {
     "auth_ref": [
      "r14",
      "r389",
      "r401"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "stringItemType"
    },
    "us-gaap_SupplyCommitmentMember": {
     "auth_ref": [
      "r14",
      "r389",
      "r401"
     ],
     "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 [Member]"
       }
      }
     },
     "localname": "SupplyCommitmentMember",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesOtherCommitmentsDetails"
     ],
     "xbrltype": "domainItemType"
    },
    "us-gaap_SupplyCommitmentTableTextBlock": {
     "auth_ref": [
      "r14"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CommitmentsandContingenciesTables"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_UnbilledReceivablesCurrent": {
     "auth_ref": [],
     "calculation": {
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets": {
       "order": 1.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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedBalanceSheets",
      "http://www.codexis.com/role/RevenueRecognitionContractswithCustomerDetails"
     ],
     "xbrltype": "monetaryItemType"
    },
    "us-gaap_UseOfEstimates": {
     "auth_ref": [
      "r126",
      "r127",
      "r128",
      "r129",
      "r136",
      "r137",
      "r138"
     ],
     "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/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/BasisofPresentationandSummaryofSignificantAccountingPoliciesPolicies"
     ],
     "xbrltype": "textBlockItemType"
    },
    "us-gaap_VestingAxis": {
     "auth_ref": [
      "r308"
     ],
     "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/2020-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": [
      "r308"
     ],
     "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/2020-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_WeightedAverageNumberOfDilutedSharesOutstanding": {
     "auth_ref": [
      "r107",
      "r114"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "WeightedAverageNumberOfDilutedSharesOutstanding",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "sharesItemType"
    },
    "us-gaap_WeightedAverageNumberOfSharesOutstandingBasic": {
     "auth_ref": [
      "r106",
      "r114"
     ],
     "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 (shares)"
       }
      }
     },
     "localname": "WeightedAverageNumberOfSharesOutstandingBasic",
     "nsuri": "http://fasb.org/us-gaap/2020-01-31",
     "presentation": [
      "http://www.codexis.com/role/CondensedConsolidatedStatementsofOperations"
     ],
     "xbrltype": "sharesItemType"
    }
   },
   "unitCount": 9
  }
 },
 "std_ref": {
  "r0": {
   "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"
  },
  "r1": {
   "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"
  },
  "r10": {
   "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"
  },
  "r100": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22583-107794"
  },
  "r101": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22595-107794"
  },
  "r102": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22644-107794"
  },
  "r103": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22644-107794"
  },
  "r104": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22658-107794"
  },
  "r105": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22663-107794"
  },
  "r106": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e1448-109256"
  },
  "r107": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "16",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e1505-109256"
  },
  "r108": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e1252-109256"
  },
  "r109": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e1278-109256"
  },
  "r11": {
   "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"
  },
  "r110": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "55",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e2626-109256"
  },
  "r111": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "60B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=SL5780133-109256"
  },
  "r112": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "60B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=SL5780133-109256"
  },
  "r113": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=121326447&loc=d3e1337-109256"
  },
  "r114": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=6371337&loc=d3e3550-109257"
  },
  "r115": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=6371337&loc=d3e3550-109257"
  },
  "r116": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=6371337&loc=d3e3630-109257"
  },
  "r117": {
   "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"
  },
  "r118": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=120380238&loc=d3e3842-109258"
  },
  "r119": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "52",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Topic": "260",
   "URI": "http://asc.fasb.org/extlink&oid=120380238&loc=d3e4984-109258"
  },
  "r12": {
   "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"
  },
  "r120": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "260",
   "URI": "http://asc.fasb.org/topic&trid=2144383"
  },
  "r121": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=6828210&loc=d3e70191-108054"
  },
  "r122": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "272",
   "URI": "http://asc.fasb.org/extlink&oid=6828210&loc=d3e70229-108054"
  },
  "r123": {
   "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"
  },
  "r124": {
   "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"
  },
  "r125": {
   "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"
  },
  "r126": {
   "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"
  },
  "r127": {
   "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"
  },
  "r128": {
   "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"
  },
  "r129": {
   "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"
  },
  "r13": {
   "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"
  },
  "r130": {
   "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"
  },
  "r131": {
   "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"
  },
  "r132": {
   "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"
  },
  "r133": {
   "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"
  },
  "r134": {
   "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"
  },
  "r135": {
   "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"
  },
  "r136": {
   "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"
  },
  "r137": {
   "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"
  },
  "r138": {
   "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"
  },
  "r139": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "275",
   "URI": "http://asc.fasb.org/topic&trid=2134479"
  },
  "r14": {
   "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"
  },
  "r140": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8657-108599"
  },
  "r141": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "18",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8672-108599"
  },
  "r142": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8721-108599"
  },
  "r143": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8721-108599"
  },
  "r144": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r145": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r146": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r147": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r148": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r149": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r15": {
   "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"
  },
  "r150": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r151": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(h)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r152": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(j)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r153": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "22",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8736-108599"
  },
  "r154": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8813-108599"
  },
  "r155": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8813-108599"
  },
  "r156": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8813-108599"
  },
  "r157": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "26",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8844-108599"
  },
  "r158": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r159": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r16": {
   "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"
  },
  "r160": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r161": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r162": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r163": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "29",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8864-108599"
  },
  "r164": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8906-108599"
  },
  "r165": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8906-108599"
  },
  "r166": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8906-108599"
  },
  "r167": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8906-108599"
  },
  "r168": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "30",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8906-108599"
  },
  "r169": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "31",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8924-108599"
  },
  "r17": {
   "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"
  },
  "r170": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r171": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r172": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r173": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r174": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r175": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "32",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8933-108599"
  },
  "r176": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "34",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8981-108599"
  },
  "r177": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e8475-108599"
  },
  "r178": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "40",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e9031-108599"
  },
  "r179": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e9038-108599"
  },
  "r18": {
   "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"
  },
  "r180": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e9038-108599"
  },
  "r181": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "41",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e9038-108599"
  },
  "r182": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "42",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "280",
   "URI": "http://asc.fasb.org/extlink&oid=120311839&loc=d3e9054-108599"
  },
  "r183": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "280",
   "URI": "http://asc.fasb.org/topic&trid=2134510"
  },
  "r184": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121593590&loc=d3e4647-111522"
  },
  "r185": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121593590&loc=d3e4428-111522"
  },
  "r186": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121593590&loc=d3e4531-111522"
  },
  "r187": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121611835&loc=SL6953423-111524"
  },
  "r188": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121611835&loc=d3e5074-111524"
  },
  "r189": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121611835&loc=d3e5111-111524"
  },
  "r19": {
   "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"
  },
  "r190": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "310",
   "URI": "http://asc.fasb.org/extlink&oid=121611835&loc=SL6953401-111524"
  },
  "r191": {
   "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=27010918&loc=d3e74512-122707"
  },
  "r192": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121553693&loc=d3e26610-111562"
  },
  "r193": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121645371&loc=d3e27161-111563"
  },
  "r194": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(aa)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121645371&loc=d3e27161-111563"
  },
  "r195": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121645371&loc=d3e27161-111563"
  },
  "r196": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121645371&loc=d3e27161-111563"
  },
  "r197": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "320",
   "URI": "http://asc.fasb.org/extlink&oid=121645371&loc=d3e27198-111563"
  },
  "r198": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "320",
   "URI": "http://asc.fasb.org/topic&trid=2196928"
  },
  "r199": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "321",
   "URI": "http://asc.fasb.org/extlink&oid=120269885&loc=SL75117539-209714"
  },
  "r2": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6676-107765"
  },
  "r20": {
   "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"
  },
  "r200": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "321",
   "URI": "http://asc.fasb.org/extlink&oid=120269885&loc=SL75117539-209714"
  },
  "r201": {
   "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"
  },
  "r202": {
   "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"
  },
  "r203": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121646688&loc=SL121648383-210437"
  },
  "r204": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599878&loc=SL82895884-210446"
  },
  "r205": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919244-210447"
  },
  "r206": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919249-210447"
  },
  "r207": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919249-210447"
  },
  "r208": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919253-210447"
  },
  "r209": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919269-210447"
  },
  "r21": {
   "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"
  },
  "r210": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919272-210447"
  },
  "r211": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919230-210447"
  },
  "r212": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919230-210447"
  },
  "r213": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121599337&loc=SL82919236-210447"
  },
  "r214": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Subparagraph": "(e)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121647567&loc=SL82921835-210448"
  },
  "r215": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "79",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121647567&loc=SL82922352-210448"
  },
  "r216": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "80",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121647567&loc=SL82922355-210448"
  },
  "r217": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121558606&loc=SL82898722-210454"
  },
  "r218": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121582814&loc=SL82922888-210455"
  },
  "r219": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "7",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121582814&loc=SL82922895-210455"
  },
  "r22": {
   "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"
  },
  "r220": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Subparagraph": "(g)",
   "Topic": "326",
   "URI": "http://asc.fasb.org/extlink&oid=121582814&loc=SL82922900-210455"
  },
  "r221": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "40",
   "Subparagraph": "(a)",
   "Topic": "340",
   "URI": "http://asc.fasb.org/extlink&oid=68051541&loc=SL49131252-203054"
  },
  "r222": {
   "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"
  },
  "r223": {
   "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"
  },
  "r224": {
   "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"
  },
  "r225": {
   "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"
  },
  "r226": {
   "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"
  },
  "r227": {
   "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"
  },
  "r228": {
   "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"
  },
  "r229": {
   "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"
  },
  "r23": {
   "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"
  },
  "r230": {
   "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"
  },
  "r231": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Topic": "410",
   "URI": "http://asc.fasb.org/extlink&oid=6392676&loc=d3e7480-110848"
  },
  "r232": {
   "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"
  },
  "r233": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)(3)",
   "Topic": "410",
   "URI": "http://asc.fasb.org/extlink&oid=6392692&loc=d3e7535-110849"
  },
  "r234": {
   "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"
  },
  "r235": {
   "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"
  },
  "r236": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "440",
   "URI": "http://asc.fasb.org/extlink&oid=121559207&loc=d3e25336-109308"
  },
  "r237": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "440",
   "URI": "http://asc.fasb.org/extlink&oid=121559207&loc=d3e25336-109308"
  },
  "r238": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "440",
   "URI": "http://asc.fasb.org/topic&trid=2144648"
  },
  "r239": {
   "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"
  },
  "r24": {
   "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"
  },
  "r240": {
   "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"
  },
  "r241": {
   "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"
  },
  "r242": {
   "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"
  },
  "r243": {
   "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"
  },
  "r244": {
   "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"
  },
  "r245": {
   "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"
  },
  "r246": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "450",
   "URI": "http://asc.fasb.org/topic&trid=2127136"
  },
  "r247": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "15",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=121548805&loc=d3e10037-110241"
  },
  "r248": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=121555522&loc=d3e12021-110248"
  },
  "r249": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=121555522&loc=d3e12053-110248"
  },
  "r25": {
   "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"
  },
  "r250": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "460",
   "URI": "http://asc.fasb.org/extlink&oid=121596127&loc=d3e13051-110250"
  },
  "r251": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "25",
   "SubTopic": "20",
   "Topic": "470",
   "URI": "http://asc.fasb.org/extlink&oid=109126253&loc=d3e4852-112606"
  },
  "r252": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "505",
   "URI": "http://asc.fasb.org/extlink&oid=109259400&loc=d3e21463-112644"
  },
  "r253": {
   "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"
  },
  "r254": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "505",
   "URI": "http://asc.fasb.org/topic&trid=2208762"
  },
  "r255": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121556615&loc=SL49130531-203044"
  },
  "r256": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121556615&loc=SL49130532-203044"
  },
  "r257": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121556615&loc=SL49130533-203044"
  },
  "r258": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130551-203045"
  },
  "r259": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130551-203045"
  },
  "r26": {
   "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"
  },
  "r260": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130551-203045"
  },
  "r261": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130551-203045"
  },
  "r262": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130554-203045"
  },
  "r263": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130554-203045"
  },
  "r264": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130554-203045"
  },
  "r265": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130554-203045"
  },
  "r266": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130554-203045"
  },
  "r267": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130556-203045"
  },
  "r268": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(1)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130556-203045"
  },
  "r269": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(2)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130556-203045"
  },
  "r27": {
   "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"
  },
  "r270": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130558-203045"
  },
  "r271": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130543-203045"
  },
  "r272": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130543-203045"
  },
  "r273": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130545-203045"
  },
  "r274": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130549-203045"
  },
  "r275": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130549-203045"
  },
  "r276": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "9",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121604090&loc=SL49130550-203045"
  },
  "r277": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r278": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r279": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r28": {
   "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"
  },
  "r280": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r281": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r282": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r283": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "91",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=121551570&loc=SL49130690-203046-203046"
  },
  "r284": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(i)(1)",
   "Topic": "606",
   "URI": "http://asc.fasb.org/extlink&oid=113356391&loc=SL49131195-203048"
  },
  "r285": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "606",
   "URI": "http://asc.fasb.org/topic&trid=49130388"
  },
  "r286": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(d)(ii)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=118255775&loc=d3e1928-114920"
  },
  "r287": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r288": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r289": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r29": {
   "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"
  },
  "r290": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r291": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r292": {
   "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=118255775&loc=d3e1928-114920"
  },
  "r293": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(n)",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=118255775&loc=d3e1928-114920"
  },
  "r294": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "17",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "715",
   "URI": "http://asc.fasb.org/extlink&oid=118257860&loc=d3e4179-114921"
  },
  "r295": {
   "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"
  },
  "r296": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "35",
   "SubTopic": "10",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=121326096&loc=d3e4534-113899"
  },
  "r297": {
   "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"
  },
  "r298": {
   "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"
  },
  "r299": {
   "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"
  },
  "r3": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6676-107765"
  },
  "r30": {
   "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"
  },
  "r300": {
   "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"
  },
  "r301": {
   "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"
  },
  "r302": {
   "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"
  },
  "r303": {
   "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"
  },
  "r304": {
   "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"
  },
  "r305": {
   "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"
  },
  "r306": {
   "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"
  },
  "r307": {
   "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"
  },
  "r308": {
   "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"
  },
  "r309": {
   "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"
  },
  "r31": {
   "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"
  },
  "r310": {
   "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"
  },
  "r311": {
   "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"
  },
  "r312": {
   "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"
  },
  "r313": {
   "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"
  },
  "r314": {
   "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=115993241&loc=d3e301413-122809"
  },
  "r315": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120383193&loc=d3e11149-113907"
  },
  "r316": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "718",
   "URI": "http://asc.fasb.org/extlink&oid=120383193&loc=d3e11178-113907"
  },
  "r317": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "718",
   "URI": "http://asc.fasb.org/topic&trid=2228938"
  },
  "r318": {
   "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"
  },
  "r319": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "10",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=84230637&loc=d3e32672-109319"
  },
  "r32": {
   "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"
  },
  "r320": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)(2)",
   "Topic": "740"
  },
  "r321": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "10",
   "Subparagraph": "(d)(3)",
   "Topic": "740"
  },
  "r322": {
   "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=116825942&loc=d3e330036-122817"
  },
  "r323": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "740",
   "URI": "http://asc.fasb.org/extlink&oid=120385591&loc=d3e38679-109324"
  },
  "r324": {
   "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"
  },
  "r325": {
   "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"
  },
  "r326": {
   "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"
  },
  "r327": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(bb)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=121559654&loc=d3e5710-111685"
  },
  "r328": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "810",
   "URI": "http://asc.fasb.org/extlink&oid=121559654&loc=d3e5710-111685"
  },
  "r329": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=117815213&loc=d3e19207-110258"
  },
  "r33": {
   "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"
  },
  "r330": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=117815213&loc=d3e19207-110258"
  },
  "r331": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(bb)",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=117815213&loc=d3e19207-110258"
  },
  "r332": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "820",
   "URI": "http://asc.fasb.org/extlink&oid=117815213&loc=d3e19279-110258"
  },
  "r333": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "820",
   "URI": "http://asc.fasb.org/topic&trid=2155941"
  },
  "r334": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "20",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=121572278&loc=d3e13531-108611"
  },
  "r335": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=121572278&loc=d3e13537-108611"
  },
  "r336": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "21",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=121572278&loc=d3e13537-108611"
  },
  "r337": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "825",
   "URI": "http://asc.fasb.org/extlink&oid=75031198&loc=d3e14064-108612"
  },
  "r338": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "230",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=98513438&loc=d3e33268-110906"
  },
  "r339": {
   "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"
  },
  "r34": {
   "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"
  },
  "r340": {
   "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"
  },
  "r341": {
   "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"
  },
  "r342": {
   "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"
  },
  "r343": {
   "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"
  },
  "r344": {
   "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"
  },
  "r345": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "30",
   "Topic": "830",
   "URI": "http://asc.fasb.org/extlink&oid=6450520&loc=d3e32618-110901"
  },
  "r346": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121603541&loc=SL77918627-209977"
  },
  "r347": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121603541&loc=SL77918627-209977"
  },
  "r348": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121603541&loc=SL77918638-209977"
  },
  "r349": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121603541&loc=SL77918643-209977"
  },
  "r35": {
   "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"
  },
  "r350": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121603541&loc=SL77918643-209977"
  },
  "r351": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)(3)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918673-209980"
  },
  "r352": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918673-209980"
  },
  "r353": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(a)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r354": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(b)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r355": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(c)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r356": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(e)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r357": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(1)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r358": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(3)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r359": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Subparagraph": "(g)(4)",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r36": {
   "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"
  },
  "r360": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918686-209980"
  },
  "r361": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "6",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121609121&loc=SL77918701-209980"
  },
  "r362": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "53",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "20",
   "Topic": "842",
   "URI": "http://asc.fasb.org/extlink&oid=121568110&loc=SL77918982-209971"
  },
  "r363": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "845",
   "URI": "http://asc.fasb.org/extlink&oid=68069686&loc=d3e32049-108421"
  },
  "r364": {
   "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"
  },
  "r365": {
   "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"
  },
  "r366": {
   "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"
  },
  "r367": {
   "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"
  },
  "r368": {
   "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"
  },
  "r369": {
   "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"
  },
  "r37": {
   "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"
  },
  "r370": {
   "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"
  },
  "r371": {
   "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"
  },
  "r372": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "850",
   "URI": "http://asc.fasb.org/topic&trid=2122745"
  },
  "r373": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "855",
   "URI": "http://asc.fasb.org/extlink&oid=6842918&loc=SL6314017-165662"
  },
  "r374": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "855",
   "URI": "http://asc.fasb.org/extlink&oid=6842918&loc=SL6314017-165662"
  },
  "r375": {
   "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"
  },
  "r376": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "855",
   "URI": "http://asc.fasb.org/topic&trid=2122774"
  },
  "r377": {
   "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"
  },
  "r378": {
   "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"
  },
  "r379": {
   "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"
  },
  "r38": {
   "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"
  },
  "r380": {
   "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"
  },
  "r381": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-10(a)(32))",
   "Topic": "932",
   "URI": "http://asc.fasb.org/extlink&oid=120398226&loc=d3e511914-122862"
  },
  "r382": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-10(c)(3)(ii)(A))",
   "Topic": "932",
   "URI": "http://asc.fasb.org/extlink&oid=120398226&loc=d3e511914-122862"
  },
  "r383": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-10(c)(7)(ii))",
   "Topic": "932",
   "URI": "http://asc.fasb.org/extlink&oid=120398226&loc=d3e511914-122862"
  },
  "r384": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "235",
   "Subparagraph": "(b)",
   "Topic": "932",
   "URI": "http://asc.fasb.org/extlink&oid=68064819&loc=SL6806780-109447"
  },
  "r385": {
   "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"
  },
  "r386": {
   "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"
  },
  "r387": {
   "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"
  },
  "r388": {
   "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"
  },
  "r389": {
   "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"
  },
  "r39": {
   "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"
  },
  "r390": {
   "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"
  },
  "r391": {
   "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"
  },
  "r392": {
   "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"
  },
  "r393": {
   "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"
  },
  "r394": {
   "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"
  },
  "r395": {
   "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"
  },
  "r396": {
   "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"
  },
  "r397": {
   "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"
  },
  "r398": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3A",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "320",
   "Subparagraph": "(a)",
   "Topic": "942",
   "URI": "http://asc.fasb.org/extlink&oid=120252992&loc=SL120269850-112803"
  },
  "r399": {
   "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"
  },
  "r4": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6676-107765"
  },
  "r40": {
   "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"
  },
  "r400": {
   "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"
  },
  "r401": {
   "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"
  },
  "r402": {
   "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"
  },
  "r403": {
   "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"
  },
  "r404": {
   "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"
  },
  "r405": {
   "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"
  },
  "r406": {
   "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"
  },
  "r407": {
   "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"
  },
  "r408": {
   "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"
  },
  "r409": {
   "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"
  },
  "r41": {
   "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"
  },
  "r410": {
   "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"
  },
  "r411": {
   "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"
  },
  "r412": {
   "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"
  },
  "r413": {
   "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"
  },
  "r414": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(a)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121639165&loc=SL117783719-158441"
  },
  "r415": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(b)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121639165&loc=SL117783719-158441"
  },
  "r416": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13H",
   "Publisher": "FASB",
   "Section": "55",
   "SubTopic": "40",
   "Subparagraph": "(c)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121639165&loc=SL117783719-158441"
  },
  "r417": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(e)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121370832&loc=SL117420844-207641"
  },
  "r418": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(f)(1)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121370832&loc=SL117420844-207641"
  },
  "r419": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(f)(2)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121370832&loc=SL117420844-207641"
  },
  "r42": {
   "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"
  },
  "r420": {
   "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=121370832&loc=SL117420844-207641"
  },
  "r421": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "65",
   "SubTopic": "40",
   "Subparagraph": "(h)(2)",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=121370832&loc=SL117420844-207641"
  },
  "r422": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "825",
   "Topic": "944",
   "URI": "http://asc.fasb.org/extlink&oid=99380617&loc=SL75241803-196195"
  },
  "r423": {
   "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"
  },
  "r424": {
   "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"
  },
  "r425": {
   "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=120401592&loc=d3e611197-123010"
  },
  "r426": {
   "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"
  },
  "r427": {
   "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"
  },
  "r428": {
   "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"
  },
  "r429": {
   "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"
  },
  "r43": {
   "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"
  },
  "r430": {
   "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"
  },
  "r431": {
   "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"
  },
  "r432": {
   "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"
  },
  "r433": {
   "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"
  },
  "r434": {
   "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"
  },
  "r435": {
   "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"
  },
  "r436": {
   "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"
  },
  "r437": {
   "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"
  },
  "r438": {
   "Name": "Exchange Act",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "b"
  },
  "r439": {
   "Name": "Exchange Act",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "d1-1"
  },
  "r44": {
   "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"
  },
  "r440": {
   "Name": "Form 10-Q",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "308",
   "Subsection": "a"
  },
  "r441": {
   "Name": "Forms 10-K, 10-Q, 20-F",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "13",
   "Subsection": "a-1"
  },
  "r442": {
   "Name": "Regulation 12B",
   "Number": "240",
   "Publisher": "SEC",
   "Section": "12",
   "Subsection": "b-2"
  },
  "r443": {
   "Name": "Regulation S-T",
   "Number": "232",
   "Publisher": "SEC",
   "Section": "405"
  },
  "r45": {
   "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"
  },
  "r46": {
   "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"
  },
  "r47": {
   "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"
  },
  "r48": {
   "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"
  },
  "r49": {
   "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"
  },
  "r5": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6676-107765"
  },
  "r50": {
   "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"
  },
  "r51": {
   "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"
  },
  "r52": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1A",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=121641772&loc=SL7669619-108580"
  },
  "r53": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1B",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "220",
   "URI": "http://asc.fasb.org/extlink&oid=121641772&loc=SL7669625-108580"
  },
  "r54": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r55": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r56": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r57": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r58": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r59": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r6": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6801-107765"
  },
  "r60": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r61": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r62": {
   "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=120395209&loc=SL114868664-224227"
  },
  "r63": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "12",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3179-108585"
  },
  "r64": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(c)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3213-108585"
  },
  "r65": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "13",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3213-108585"
  },
  "r66": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "14",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3255-108585"
  },
  "r67": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "15",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3291-108585"
  },
  "r68": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "17",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(d)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3367-108585"
  },
  "r69": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "24",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3521-108585"
  },
  "r7": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6812-107765"
  },
  "r70": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3536-108585"
  },
  "r71": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(e)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3536-108585"
  },
  "r72": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(g)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3536-108585"
  },
  "r73": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "25",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3536-108585"
  },
  "r74": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3602-108585"
  },
  "r75": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3602-108585"
  },
  "r76": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "28",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3602-108585"
  },
  "r77": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121586364&loc=d3e3044-108585"
  },
  "r78": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "2",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121583591&loc=d3e4297-108586"
  },
  "r79": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121583591&loc=d3e4304-108586"
  },
  "r8": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(f)",
   "Topic": "210",
   "URI": "http://asc.fasb.org/extlink&oid=121566466&loc=d3e6812-107765"
  },
  "r80": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "4",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121583591&loc=d3e4313-108586"
  },
  "r81": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121583591&loc=d3e4332-108586"
  },
  "r82": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "8",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "230",
   "URI": "http://asc.fasb.org/extlink&oid=121583591&loc=SL98516268-108586"
  },
  "r83": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "3",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=84158767&loc=d3e18780-107790"
  },
  "r84": {
   "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"
  },
  "r85": {
   "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"
  },
  "r86": {
   "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"
  },
  "r87": {
   "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"
  },
  "r88": {
   "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"
  },
  "r89": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08(k))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r9": {
   "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"
  },
  "r90": {
   "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"
  },
  "r91": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "S99",
   "SubTopic": "10",
   "Subparagraph": "(SX 210.4-08.(h)(1)(i))",
   "Topic": "235",
   "URI": "http://asc.fasb.org/extlink&oid=120395691&loc=d3e23780-122690"
  },
  "r92": {
   "Name": "Accounting Standards Codification",
   "Publisher": "FASB",
   "Topic": "235",
   "URI": "http://asc.fasb.org/topic&trid=2122369"
  },
  "r93": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "23",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=115929471&loc=d3e21914-107793"
  },
  "r94": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "24",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=115929471&loc=d3e21930-107793"
  },
  "r95": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "5",
   "Publisher": "FASB",
   "Section": "45",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=115929471&loc=d3e21711-107793"
  },
  "r96": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(2)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22499-107794"
  },
  "r97": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "1",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)(3)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22499-107794"
  },
  "r98": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(a)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22694-107794"
  },
  "r99": {
   "Name": "Accounting Standards Codification",
   "Paragraph": "11",
   "Publisher": "FASB",
   "Section": "50",
   "SubTopic": "10",
   "Subparagraph": "(b)",
   "Topic": "250",
   "URI": "http://asc.fasb.org/extlink&oid=109234566&loc=d3e22694-107794"
  }
 },
 "version": "2.1"
}
