<?xml version='1.0' encoding='utf-8'?>
<FilingSummary>
  <Version>3.19.1</Version>
  <ProcessingTime/>
  <ReportFormat>html</ReportFormat>
  <ContextCount>286</ContextCount>
  <ElementCount>259</ElementCount>
  <EntityCount>1</EntityCount>
  <FootnotesReported>true</FootnotesReported>
  <SegmentCount>60</SegmentCount>
  <ScenarioCount>0</ScenarioCount>
  <TuplesReported>false</TuplesReported>
  <UnitCount>8</UnitCount>
  <MyReports>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R1.htm</HtmlFileName>
      <LongName>00090 - Document - Document And Entity Information</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DocumentDocumentAndEntityInformation</Role>
      <ShortName>Document And Entity Information</ShortName>
      <MenuCategory>Cover</MenuCategory>
      <Position>1</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R2.htm</HtmlFileName>
      <LongName>00100 - Statement - Consolidated Balance Sheets</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedBalanceSheets</Role>
      <ShortName>Consolidated Balance Sheets</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>2</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R3.htm</HtmlFileName>
      <LongName>00105 - Statement - Consolidated Balance Sheets (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedBalanceSheetsParenthetical</Role>
      <ShortName>Consolidated Balance Sheets (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>3</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R4.htm</HtmlFileName>
      <LongName>00200 - Statement - Consolidated Statements Of Income</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedStatementsOfIncome</Role>
      <ShortName>Consolidated Statements Of Income</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>4</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R5.htm</HtmlFileName>
      <LongName>00300 - Statement - Consolidated Statements Of Comprehensive Income</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedStatementsOfComprehensiveIncome</Role>
      <ShortName>Consolidated Statements Of Comprehensive Income</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>5</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R6.htm</HtmlFileName>
      <LongName>00400 - Statement - Consolidated Statements Of Cash Flows</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedStatementsOfCashFlows</Role>
      <ShortName>Consolidated Statements Of Cash Flows</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>6</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R7.htm</HtmlFileName>
      <LongName>00500 - Statement - Consolidated Statements Of Changes In Stockholders' Equity</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedStatementsOfChangesInStockholdersEquity</Role>
      <ShortName>Consolidated Statements Of Changes In Stockholders' Equity</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>7</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R8.htm</HtmlFileName>
      <LongName>00505 - Statement - Consolidated Statements Of Changes In Stockholders' Equity (Parenthetical)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/StatementConsolidatedStatementsOfChangesInStockholdersEquityParenthetical</Role>
      <ShortName>Consolidated Statements Of Changes In Stockholders' Equity (Parenthetical)</ShortName>
      <MenuCategory>Statements</MenuCategory>
      <Position>8</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R9.htm</HtmlFileName>
      <LongName>10101 - Disclosure - Basis Of Presentation</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBasisOfPresentation</Role>
      <ShortName>Basis Of Presentation</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>9</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R10.htm</HtmlFileName>
      <LongName>10201 - Disclosure - Use Of Estimates</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureUseOfEstimates</Role>
      <ShortName>Use Of Estimates</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>10</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R11.htm</HtmlFileName>
      <LongName>10301 - Disclosure - Earnings Per Common Share (EPS)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEps</Role>
      <ShortName>Earnings Per Common Share (EPS)</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>11</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R12.htm</HtmlFileName>
      <LongName>10401 - Disclosure - Stock Based Compensation</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureStockBasedCompensation</Role>
      <ShortName>Stock Based Compensation</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>12</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R13.htm</HtmlFileName>
      <LongName>10501 - Disclosure - Fair Value Measurements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurements</Role>
      <ShortName>Fair Value Measurements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>13</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R14.htm</HtmlFileName>
      <LongName>10601 - Disclosure - Leases</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeases</Role>
      <ShortName>Leases</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>14</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R15.htm</HtmlFileName>
      <LongName>10701 - Disclosure - Securities</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureSecurities</Role>
      <ShortName>Securities</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>15</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R16.htm</HtmlFileName>
      <LongName>10801 - Disclosure - Business Segments</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBusinessSegments</Role>
      <ShortName>Business Segments</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>16</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R17.htm</HtmlFileName>
      <LongName>10901 - Disclosure - Loans, Allowance For Loan Losses And OREO</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreo</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>17</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R18.htm</HtmlFileName>
      <LongName>11001 - Disclosure - Revenue Recognition</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureRevenueRecognition</Role>
      <ShortName>Revenue Recognition</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>18</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R19.htm</HtmlFileName>
      <LongName>11101 - Disclosure - Recent Accounting Pronouncements</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureRecentAccountingPronouncements</Role>
      <ShortName>Recent Accounting Pronouncements</ShortName>
      <MenuCategory>Notes</MenuCategory>
      <Position>19</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R20.htm</HtmlFileName>
      <LongName>30303 - Disclosure - Earnings Per Common Share (EPS) (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEpsTables</Role>
      <ShortName>Earnings Per Common Share (EPS) (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEps</ParentRole>
      <Position>20</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R21.htm</HtmlFileName>
      <LongName>30503 - Disclosure - Fair Value Measurements (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</Role>
      <ShortName>Fair Value Measurements (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurements</ParentRole>
      <Position>21</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R22.htm</HtmlFileName>
      <LongName>30603 - Disclosure - Leases (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeasesTables</Role>
      <ShortName>Leases (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLeases</ParentRole>
      <Position>22</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R23.htm</HtmlFileName>
      <LongName>30703 - Disclosure - Securities (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureSecuritiesTables</Role>
      <ShortName>Securities (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureSecurities</ParentRole>
      <Position>23</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R24.htm</HtmlFileName>
      <LongName>30803 - Disclosure - Business Segments (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBusinessSegmentsTables</Role>
      <ShortName>Business Segments (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureBusinessSegments</ParentRole>
      <Position>24</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R25.htm</HtmlFileName>
      <LongName>30903 - Disclosure - Loans, Allowance For Loan Losses And OREO (Tables)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoTables</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO (Tables)</ShortName>
      <MenuCategory>Tables</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreo</ParentRole>
      <Position>25</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R26.htm</HtmlFileName>
      <LongName>40101 - Disclosure - Basis Of Presentation (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBasisOfPresentationNarrativeDetails</Role>
      <ShortName>Basis Of Presentation (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureBasisOfPresentation</ParentRole>
      <Position>26</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R27.htm</HtmlFileName>
      <LongName>40301 - Disclosure - Earnings Per Common Share (EPS) (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEpsNarrativeDetails</Role>
      <ShortName>Earnings Per Common Share (EPS) (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEpsTables</ParentRole>
      <Position>27</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R28.htm</HtmlFileName>
      <LongName>40302 - Disclosure - Earnings Per Common Share (EPS) (Earnings Per Share) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEpsEarningsPerShareDetails</Role>
      <ShortName>Earnings Per Common Share (EPS) (Earnings Per Share) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureEarningsPerCommonShareEpsTables</ParentRole>
      <Position>28</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R29.htm</HtmlFileName>
      <LongName>40401 - Disclosure - Stock Based Compensation (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureStockBasedCompensationNarrativeDetails</Role>
      <ShortName>Stock Based Compensation (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureStockBasedCompensation</ParentRole>
      <Position>29</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R30.htm</HtmlFileName>
      <LongName>40501 - Disclosure - Fair Value Measurements (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsNarrativeDetails</Role>
      <ShortName>Fair Value Measurements (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</ParentRole>
      <Position>30</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R31.htm</HtmlFileName>
      <LongName>40502 - Disclosure - Fair Value Measurements (Fair Value Assets Measured On Recurring Basis) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsFairValueAssetsMeasuredOnRecurringBasisDetails</Role>
      <ShortName>Fair Value Measurements (Fair Value Assets Measured On Recurring Basis) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</ParentRole>
      <Position>31</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R32.htm</HtmlFileName>
      <LongName>40503 - Disclosure - Fair Value Measurements (Impaired Loans And Other Real Estate Owned Measured At Fair Value On A Nonrecurring Basis) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsImpairedLoansAndOtherRealEstateOwnedMeasuredAtFairValueOnNonrecurringBasisDetails</Role>
      <ShortName>Fair Value Measurements (Impaired Loans And Other Real Estate Owned Measured At Fair Value On A Nonrecurring Basis) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</ParentRole>
      <Position>32</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R33.htm</HtmlFileName>
      <LongName>40504 - Disclosure - Fair Value Measurements (Information Regarding Quantitative Inputs Used To Value Assets Classified As Level 3) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsInformationRegardingQuantitativeInputsUsedToValueAssetsClassifiedAsLevel3Details</Role>
      <ShortName>Fair Value Measurements (Information Regarding Quantitative Inputs Used To Value Assets Classified As Level 3) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</ParentRole>
      <Position>33</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R34.htm</HtmlFileName>
      <LongName>40505 - Disclosure - Fair Value Measurements (Fair Value Carrying And Notional Amounts) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsFairValueCarryingAndNotionalAmountsDetails</Role>
      <ShortName>Fair Value Measurements (Fair Value Carrying And Notional Amounts) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureFairValueMeasurementsTables</ParentRole>
      <Position>34</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R35.htm</HtmlFileName>
      <LongName>40601 - Disclosure - Leases (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeasesNarrativeDetails</Role>
      <ShortName>Leases (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLeasesTables</ParentRole>
      <Position>35</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R36.htm</HtmlFileName>
      <LongName>40602 - Disclosure - Leases (Information On Leases) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeasesInformationOnLeasesDetails</Role>
      <ShortName>Leases (Information On Leases) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLeasesTables</ParentRole>
      <Position>36</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R37.htm</HtmlFileName>
      <LongName>40603 - Disclosure - Leases (Schedule Of Lease Cost) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeasesScheduleOfLeaseCostDetails</Role>
      <ShortName>Leases (Schedule Of Lease Cost) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLeasesTables</ParentRole>
      <Position>37</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R38.htm</HtmlFileName>
      <LongName>40604 - Disclosure - Leases (Maturity Analysis For Operating Lease Liabilities And Reconciliation Of Undiscounted Cash Flows) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLeasesMaturityAnalysisForOperatingLeaseLiabilitiesAndReconciliationOfUndiscountedCashFlowsDetails</Role>
      <ShortName>Leases (Maturity Analysis For Operating Lease Liabilities And Reconciliation Of Undiscounted Cash Flows) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLeasesTables</ParentRole>
      <Position>38</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R39.htm</HtmlFileName>
      <LongName>40701 - Disclosure - Securities (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureSecuritiesNarrativeDetails</Role>
      <ShortName>Securities (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureSecuritiesTables</ParentRole>
      <Position>39</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R40.htm</HtmlFileName>
      <LongName>40702 - Disclosure - Securities (Summary Of Securities Held-To-Maturity And Securities Available-For-Sale) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureSecuritiesSummaryOfSecuritiesHeldToMaturityAndSecuritiesAvailableForSaleDetails</Role>
      <ShortName>Securities (Summary Of Securities Held-To-Maturity And Securities Available-For-Sale) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureSecuritiesTables</ParentRole>
      <Position>40</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R41.htm</HtmlFileName>
      <LongName>40703 - Disclosure - Securities (Gross Unrealized Losses And Fair Value Of The Bank's Investments) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureSecuritiesGrossUnrealizedLossesAndFairValueOfBankSInvestmentsDetails</Role>
      <ShortName>Securities (Gross Unrealized Losses And Fair Value Of The Bank's Investments) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureSecuritiesTables</ParentRole>
      <Position>41</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R42.htm</HtmlFileName>
      <LongName>40801 - Disclosure - Business Segments (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBusinessSegmentsNarrativeDetails</Role>
      <ShortName>Business Segments (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureBusinessSegmentsTables</ParentRole>
      <Position>42</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R43.htm</HtmlFileName>
      <LongName>40802 - Disclosure - Business Segments (Schedule Of Segment Reporting Information, By Segment) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureBusinessSegmentsScheduleOfSegmentReportingInformationBySegmentDetails</Role>
      <ShortName>Business Segments (Schedule Of Segment Reporting Information, By Segment) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureBusinessSegmentsTables</ParentRole>
      <Position>43</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R44.htm</HtmlFileName>
      <LongName>40901 - Disclosure - Loans, Allowance For Loan Losses And OREO (Narrative) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoNarrativeDetails</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO (Narrative) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoTables</ParentRole>
      <Position>44</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R45.htm</HtmlFileName>
      <LongName>40902 - Disclosure - Loans, Allowance For Loan Losses And OREO (Summary Of Loans, Net) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoSummaryOfLoansNetDetails</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO (Summary Of Loans, Net) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoTables</ParentRole>
      <Position>45</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R46.htm</HtmlFileName>
      <LongName>40903 - Disclosure - Loans, Allowance For Loan Losses And OREO (Loans On Non-Accrual Status) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoLoansOnNonAccrualStatusDetails</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO (Loans On Non-Accrual Status) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoTables</ParentRole>
      <Position>46</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R47.htm</HtmlFileName>
      <LongName>40904 - Disclosure - Loans, Allowance For Loan Losses And OREO (Changes In OREO Balance) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoChangesInOreoBalanceDetails</Role>
      <ShortName>Loans, Allowance For Loan Losses And OREO (Changes In OREO Balance) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <ParentRole>http://www.bankofthejames.com/role/DisclosureLoansAllowanceForLoanLossesAndOreoTables</ParentRole>
      <Position>47</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R48.htm</HtmlFileName>
      <LongName>40905 - Disclosure - Loans And Allowance For Loan Losses (Impaired Loans) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAndAllowanceForLoanLossesImpairedLoansDetails</Role>
      <ShortName>Loans And Allowance For Loan Losses (Impaired Loans) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>48</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R49.htm</HtmlFileName>
      <LongName>40907 - Disclosure - Loans And Allowance For Loan Losses (Allowance For Loan Losses And Recorded Investment In Loans) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAndAllowanceForLoanLossesAllowanceForLoanLossesAndRecordedInvestmentInLoansDetails</Role>
      <ShortName>Loans And Allowance For Loan Losses (Allowance For Loan Losses And Recorded Investment In Loans) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>49</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R50.htm</HtmlFileName>
      <LongName>40908 - Disclosure - Loans And Allowance For Loan Losses (Age Analysis Of Past Due Financing Receivables) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAndAllowanceForLoanLossesAgeAnalysisOfPastDueFinancingReceivablesDetails</Role>
      <ShortName>Loans And Allowance For Loan Losses (Age Analysis Of Past Due Financing Receivables) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>50</Position>
    </Report>
    <Report instance="botj-20190331.xml">
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <HtmlFileName>R51.htm</HtmlFileName>
      <LongName>40909 - Disclosure - Loans And Allowance For Loan Losses (Credit Quality Information-By Class) (Details)</LongName>
      <ReportType>Sheet</ReportType>
      <Role>http://www.bankofthejames.com/role/DisclosureLoansAndAllowanceForLoanLossesCreditQualityInformationByClassDetails</Role>
      <ShortName>Loans And Allowance For Loan Losses (Credit Quality Information-By Class) (Details)</ShortName>
      <MenuCategory>Details</MenuCategory>
      <Position>51</Position>
    </Report>
    <Report>
      <IsDefault>false</IsDefault>
      <HasEmbeddedReports>false</HasEmbeddedReports>
      <LongName>All Reports</LongName>
      <ReportType>Book</ReportType>
      <ShortName>All Reports</ShortName>
    </Report>
  </MyReports>
  <InputFiles>
    <File>botj-20190331.xml</File>
    <File>botj-20190331.xsd</File>
    <File>botj-20190331_cal.xml</File>
    <File>botj-20190331_def.xml</File>
    <File>botj-20190331_lab.xml</File>
    <File>botj-20190331_pre.xml</File>
  </InputFiles>
  <SupplementalFiles/>
  <BaseTaxonomies>
    <BaseTaxonomy>http://fasb.org/srt/2018-01-31</BaseTaxonomy>
    <BaseTaxonomy>http://xbrl.sec.gov/dei/2018-01-31</BaseTaxonomy>
    <BaseTaxonomy>http://fasb.org/us-gaap/2018-01-31</BaseTaxonomy>
  </BaseTaxonomies>
  <HasPresentationLinkbase>true</HasPresentationLinkbase>
  <HasCalculationLinkbase>true</HasCalculationLinkbase>
</FilingSummary>
