<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xml:lang="en-US"
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2019-01-31"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:xlink="http://www.w3.org/1999/xlink">
    <link:schemaRef xlink:href="bhe-20201028.xsd" xlink:type="simple"/>
    <context id="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000863436</identifier>
        </entity>
        <period>
            <startDate>2020-10-28</startDate>
            <endDate>2020-10-28</endDate>
        </period>
    </context>
    <dei:EntityCentralIndexKey
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_19">0000863436</dei:EntityCentralIndexKey>
    <dei:AmendmentFlag
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_20">false</dei:AmendmentFlag>
    <dei:DocumentType
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_0">8-K</dei:DocumentType>
    <dei:DocumentPeriodEndDate
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_21">2020-10-28</dei:DocumentPeriodEndDate>
    <dei:EntityRegistrantName
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_1">BENCHMARK ELECTRONICS, INC.</dei:EntityRegistrantName>
    <dei:EntityIncorporationStateCountryCode
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_6">TX</dei:EntityIncorporationStateCountryCode>
    <dei:EntityFileNumber
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_8">1-10560</dei:EntityFileNumber>
    <dei:EntityTaxIdentificationNumber
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_9">74-2211011</dei:EntityTaxIdentificationNumber>
    <dei:EntityAddressAddressLine1
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_10">56 South Rockford Drive</dei:EntityAddressAddressLine1>
    <dei:EntityAddressCityOrTown
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_11">Tempe</dei:EntityAddressCityOrTown>
    <dei:EntityAddressStateOrProvince
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_7">AZ</dei:EntityAddressStateOrProvince>
    <dei:EntityAddressPostalZipCode
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_12">85281</dei:EntityAddressPostalZipCode>
    <dei:CityAreaCode
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_13">623</dei:CityAreaCode>
    <dei:LocalPhoneNumber
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_14">300-7000</dei:LocalPhoneNumber>
    <dei:WrittenCommunications
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_5">false</dei:WrittenCommunications>
    <dei:SolicitingMaterial
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_15">false</dei:SolicitingMaterial>
    <dei:PreCommencementTenderOffer
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_16">false</dei:PreCommencementTenderOffer>
    <dei:PreCommencementIssuerTenderOffer
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_17">false</dei:PreCommencementIssuerTenderOffer>
    <dei:Security12bTitle
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_2">Common Stock, par value $0.10 per share</dei:Security12bTitle>
    <dei:TradingSymbol
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_3">BHE</dei:TradingSymbol>
    <dei:SecurityExchangeName
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_4">NYSE</dei:SecurityExchangeName>
    <dei:EntityEmergingGrowthCompany
      contextRef="FROM_Oct28_2020_TO_Oct28_2020_Entity_0000863436"
      id="ID_18">false</dei:EntityEmergingGrowthCompany>
</xbrl>
