<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.26.1</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>22</ContextCount>
  <ElementCount>34</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>false</FootnotesReported>
  <SegmentCount>9</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>2</UnitCount>
  <MyReports>
    <Report instance="bhb-20260507xdef14a.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>995200090 - Document - Document and Entity Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bhbt.com/role/DocumentDocumentAndEntityInformation</Role>
      <ShortName>Document and Entity Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="bhb-20260507xdef14a.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>995410 - Disclosure - Pay vs Performance Disclosure</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/PvpDisclosure</Role>
      <ShortName>Pay vs Performance Disclosure</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="bhb-20260507xdef14a.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>995443 - Disclosure - Award Timing Disclosure</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/AwardTimingDisclosure</Role>
      <ShortName>Award Timing Disclosure</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="bhb-20260507xdef14a.htm">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R4.htm</HtmlFileName>
      <LongName>995447 - Disclosure - Insider Trading Policies and Procedures</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://xbrl.sec.gov/ecd/role/InsiderTradingPoliciesProc</Role>
      <ShortName>Insider Trading Policies and Procedures</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report>
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <LongName>All Reports</LongName>
      <ReportType>Book</ReportType>
      <ShortName>All Reports</ShortName>
    </Report>
  </MyReports>
  <InputFiles>
    <File>bhb-20260507.xsd</File>
    <File>bhb-20260507_def.xml</File>
    <File>bhb-20260507_lab.xml</File>
    <File>bhb-20260507_pre.xml</File>
    <File doctype="DEF 14A" isProxy="true" isUsgaap="true" original="bhb-20260507xdef14a.htm">bhb-20260507xdef14a.htm</File>
  </InputFiles>
  <SupplementalFiles>
    <File>bhb-20260507xdef14a_a001.jpg</File>
    <File>bhb-20260507xdef14a_a002.jpg</File>
    <File>bhb-20260507xdef14a_a003.jpg</File>
    <File>bhb-20260507xdef14a_a004.jpg</File>
    <File>bhb-20260507xdef14a_a005.jpg</File>
    <File>bhb-20260507xdef14a_a006.jpg</File>
    <File>bhb-20260507xdef14a_a007.jpg</File>
    <File>bhb-20260507xdef14a_a008.jpg</File>
    <File>bhb-20260507xdef14a_a009.jpg</File>
    <File>bhb-20260507xdef14a_a010.jpg</File>
    <File>bhb-20260507xdef14a_a011.jpg</File>
    <File>bhb-20260507xdef14a_a014.jpg</File>
    <File>bhb-20260507xdef14a_a015.jpg</File>
    <File>bhb-20260507xdef14a_a016.jpg</File>
    <File>bhb-20260507xdef14a_a017.jpg</File>
    <File>bhb-20260507xdef14a_a018.jpg</File>
    <File>bhb-20260507xdef14a_a019.jpg</File>
    <File>bhb-20260507xdef14a_a020.jpg</File>
    <File>bhb-20260507xdef14a_a022.jpg</File>
    <File>bhb-20260507xdef14a_a023.gif</File>
    <File>bhb-20260507xdef14a_a024.gif</File>
    <File>bhb-20260507xdef14a_a025.gif</File>
    <File>bhb-20260507xdef14a_a027.gif</File>
    <File>bhb-20260507xdef14a_a029.gif</File>
    <File>bhb-20260507xdef14a_a031.gif</File>
    <File>bhb-20260507xdef14a_a032.gif</File>
    <File>bhb-20260507xdef14a_a034.gif</File>
    <File>bhb-20260507xdef14a_a036.gif</File>
    <File>bhb-20260507xdef14a_a038.gif</File>
    <File>bhb-20260507xdef14a_a039.gif</File>
    <File>bhb-20260507xdef14a_a041.jpg</File>
    <File>bhb-20260507xdef14a_a044.jpg</File>
    <File>bhb-20260507xdef14a_a045.jpg</File>
    <File>bhb-20260507xdef14a_a046.jpg</File>
    <File>bhb-20260507xdef14a_a047.jpg</File>
    <File>bhb-20260507xdef14a_a048.jpg</File>
    <File>bhb-20260507xdef14a_a049.jpg</File>
    <File>bhb-20260507xdef14a_a051.jpg</File>
    <File>bhb-20260507xdef14a_a052.jpg</File>
    <File>bhb-20260507xdef14a_a053.jpg</File>
    <File>bhb-20260507xdef14a_a054.jpg</File>
    <File>bhb-20260507xdef14a_a055.jpg</File>
    <File>bhb-20260507xdef14a_a056.jpg</File>
    <File>bhb-20260507xdef14a_a057.jpg</File>
    <File>bhb-20260507xdef14a_a058.jpg</File>
    <File>bhb-20260507xdef14a_a059.jpg</File>
    <File>bhb-20260507xdef14a_a060.jpg</File>
    <File>bhb-20260507xdef14a_a061.jpg</File>
    <File>bhb-20260507xdef14a_a062.jpg</File>
    <File>bhb-20260507xdef14a_a063.jpg</File>
    <File>bhb-20260507xdef14a_a064.jpg</File>
    <File>bhb-20260507xdef14a_a065.jpg</File>
    <File>bhb-20260507xdef14a_a066.jpg</File>
    <File>bhb-20260507xdef14a_a067.jpg</File>
    <File>bhb-20260507xdef14a_a068.jpg</File>
    <File>bhb-20260507xdef14a_a069.jpg</File>
    <File>bhb-20260507xdef14a_a070.jpg</File>
    <File>bhb-20260507xdef14a_a071.jpg</File>
    <File>bhb-20260507xdef14a_a072.jpg</File>
    <File>bhb-20260507xdef14a_a073.jpg</File>
    <File>bhb-20260507xdef14a_a079.jpg</File>
    <File>bhb-20260507xdef14a_a080.jpg</File>
    <File>bhb-20260507xdef14a_a082.jpg</File>
    <File>bhb-20260507xdef14a_a084.jpg</File>
    <File>bhb-20260507xdef14a_a086.jpg</File>
    <File>bhb-20260507xdef14a_a088.jpg</File>
    <File>bhb-20260507xdef14a_a090.jpg</File>
    <File>bhb-20260507xdef14a_a094.jpg</File>
    <File>bhb-20260507xdef14a_a097.jpg</File>
    <File>bhb-20260507xdef14a_a098.jpg</File>
    <File>bhb-20260507xdef14a_a103.jpg</File>
    <File>bhb-20260507xdef14a_a108.jpg</File>
    <File>bhb-20260507xdef14a_a113.jpg</File>
    <File>bhb-20260507xdef14a_a115.jpg</File>
    <File>bhb-20260507xdef14a_a119.jpg</File>
    <File>bhb-20260507xdef14a_a120.jpg</File>
    <File>bhb-20260507xdef14a_a123.jpg</File>
    <File>bhb-20260507xdef14a_a125.jpg</File>
    <File>bhb-20260507xdef14a_a127.jpg</File>
    <File>bhb-20260507xdef14a_a134.jpg</File>
    <File>bhb-20260507xdef14a_a135.jpg</File>
    <File>bhb-20260507xdef14a_a143.gif</File>
    <File>bhb-20260507xdef14a_a222.jpg</File>
    <File>bhb-20260507xdef14a_a223.jpg</File>
    <File>bhb-20260507xdef14a_a224.jpg</File>
    <File>bhb-20260507xdef14a_a225.jpg</File>
    <File>bhb-20260507xdef14a_a226.jpg</File>
    <File>bhb-20260507xdef14a_a227.jpg</File>
    <File>bhb-20260507xdef14a_a228.jpg</File>
    <File>bhb-20260507xdef14a_a229.jpg</File>
    <File>bhb-20260507xdef14a_a230.jpg</File>
    <File>bhb-20260507xdef14a_a232.jpg</File>
    <File>bhb-20260507xdef14a_a233.jpg</File>
    <File>bhb-20260507xdef14a_a234.jpg</File>
    <File>bhb-20260507xdef14a_a235.jpg</File>
    <File>bhb-20260507xdef14a_a236.jpg</File>
    <File>bhb-20260507xdef14a_a241.jpg</File>
    <File>bhb-20260507xdef14a_a242.jpg</File>
    <File>bhb-20260507xdef14a_a243.jpg</File>
    <File>bhb-20260507xdef14a_a244.jpg</File>
    <File>bhb-20260507xdef14a_a245.jpg</File>
    <File>bhb-20260507xdef14a_a248.jpg</File>
    <File>bhb-20260507xdef14a_a249.jpg</File>
    <File>bhb-20260507xdef14a_a253.jpg</File>
    <File>bhb-20260507xdef14a_bg001.jpg</File>
    <File>bhb-20260507xdef14a_bg002.jpg</File>
  </SupplementalFiles>
  <BaseTaxonomies>
    <BaseTaxonomy items="5">http://fasb.org/us-gaap/2025</BaseTaxonomy>
    <BaseTaxonomy items="4">http://xbrl.sec.gov/dei/2025</BaseTaxonomy>
    <BaseTaxonomy items="78">http://xbrl.sec.gov/ecd/2025</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>false</HasCalculationLinkbase>
</FilingSummary>
