<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2024"
  xmlns:ecd="http://xbrl.sec.gov/ecd/2024"
  xmlns:iso4217="http://www.xbrl.org/2003/iso4217"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:mbcn="http://www.middlefieldbank.bank/20250404"
  xmlns:us-gaap="http://fasb.org/us-gaap/2024"
  xmlns:xbrldi="http://xbrl.org/2006/xbrldi"
  xmlns:xlink="http://www.w3.org/1999/xlink"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <link:schemaRef xlink:href="mbcn-20250404.xsd" xlink:type="simple"/>
    <context id="c0">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
        </entity>
        <period>
            <startDate>2024-01-01</startDate>
            <endDate>2024-12-31</endDate>
        </period>
    </context>
    <context id="c1">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:FirstPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2024-01-01</startDate>
            <endDate>2024-12-31</endDate>
        </period>
    </context>
    <context id="c2">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:SecondPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2024-01-01</startDate>
            <endDate>2024-12-31</endDate>
        </period>
    </context>
    <context id="c3">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:FirstPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2023-01-01</startDate>
            <endDate>2023-12-31</endDate>
        </period>
    </context>
    <context id="c4">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:SecondPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2023-01-01</startDate>
            <endDate>2023-12-31</endDate>
        </period>
    </context>
    <context id="c5">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
        </entity>
        <period>
            <startDate>2023-01-01</startDate>
            <endDate>2023-12-31</endDate>
        </period>
    </context>
    <context id="c6">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:FirstPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2022-01-01</startDate>
            <endDate>2022-12-31</endDate>
        </period>
    </context>
    <context id="c7">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
            <segment>
                <xbrldi:explicitMember dimension="ecd:IndividualAxis">mbcn:SecondPEOMember</xbrldi:explicitMember>
            </segment>
        </entity>
        <period>
            <startDate>2022-01-01</startDate>
            <endDate>2022-12-31</endDate>
        </period>
    </context>
    <context id="c8">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000836147</identifier>
        </entity>
        <period>
            <startDate>2022-01-01</startDate>
            <endDate>2022-12-31</endDate>
        </period>
    </context>
    <unit id="usd">
        <measure>iso4217:USD</measure>
    </unit>
    <dei:EntityRegistrantName contextRef="c0" id="ixv-97">MIDDLEFIELD BANC CORP.</dei:EntityRegistrantName>
    <ecd:InsiderTrdPoliciesProcAdoptedFlag contextRef="c0" id="ixv-3591">false</ecd:InsiderTrdPoliciesProcAdoptedFlag>
    <ecd:PvpTableTextBlock contextRef="c0" id="ixv-2697">&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 10pt 0pt 0pt; text-align: center; text-indent: 0pt"&gt;&lt;b&gt;Pay Versus Performance
&lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0"&gt;&#160;&lt;/p&gt;

&lt;table cellpadding="0" style="font: 10pt Times New Roman, Times, Serif; width: 100%; border-collapse: collapse; border-spacing: 0px;"&gt; &lt;tr&gt; &lt;td style="padding: 0pt; text-align: center; white-space: nowrap; text-indent: 0pt; vertical-align: bottom"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; vertical-align: bottom; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt;&lt;/tr&gt; &lt;tr style="vertical-align: bottom"&gt; &lt;td style="border-top: black 1pt solid; text-align: center; white-space: nowrap; padding: 0pt; border-right: black 1pt solid; border-left: black 1pt solid; text-indent: 0pt; vertical-align: bottom"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(a)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(b)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(c)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(d)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(e)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(f)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-top: black 1pt solid; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td style="border-right: black 1pt solid; text-align: center; white-space: nowrap; padding: 0pt; border-left: black 1pt solid; text-indent: 0pt; vertical-align: bottom"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td colspan="2" style="white-space: nowrap; padding: 0pt; border-right: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt;&lt;/tr&gt; &lt;tr style="vertical-align: bottom"&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; border-left: black 1pt solid; padding: 0pt; white-space: nowrap; vertical-align: bottom; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Year&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Summary&lt;br/&gt;
Compensation&lt;br/&gt;
Table&#160;Total&#160;for&lt;br/&gt;
First&#160;PEO&#160;(1)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Summary&lt;br/&gt;
Compensation&lt;br/&gt;
Table Total for&lt;br/&gt;
Second PEO&#160;(1)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Compensation&lt;br/&gt;
Actually&#160;Paid&#160;to&lt;br/&gt;
First&#160;PEO&#160;(2)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Compensation&lt;br/&gt;
Actually&#160;Paid&#160;to&lt;br/&gt;
Second&#160;PEO&#160;&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Average&#160;Summary&lt;br/&gt;
Compensation&#160;Table&#160;&#160;&lt;br/&gt;
Total&#160;for&#160;Non-PEO&lt;br/&gt;
Named&#160;Executive&lt;br/&gt;
Officers (1)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Average&lt;br/&gt;
Compensation&lt;br/&gt;
Actually&#160;Paid&lt;br/&gt;
to Non-PEO&lt;br/&gt;
Named&lt;br/&gt;
Executive&lt;br/&gt;
Officers (3)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Value of Initial&lt;br/&gt;
Fixed $100&lt;br/&gt;
Investment&#160;Based&lt;br/&gt;
on:&lt;br/&gt;
Total&#160;Shareholder&lt;br/&gt;
Return (4)&lt;br/&gt;
($)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="white-space: nowrap; padding: 0pt; border-bottom: black 1pt solid; border-right: black 1pt solid; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;Net Income&lt;br/&gt;
($&#160;in&#160;thousands)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr style="vertical-align: bottom; background-color: #CCEEFF"&gt; &lt;td style="border-right: black 1pt solid; vertical-align: bottom; white-space: nowrap; border-bottom: black 1pt solid; border-left: black 1pt solid; padding: 0pt 0pt 9pt; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;2024&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;1,263,438&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;span style="-sec-ix-hidden: hidden-fact-1"&gt;-&lt;/span&gt;&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;1,874,321&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;span style="-sec-ix-hidden: hidden-fact-2"&gt;-&lt;/span&gt;&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;581,489&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;805,402&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;123&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;15,519&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr style="vertical-align: bottom; background-color: #CCEEFF"&gt; &lt;td style="border-right: black 1pt solid; text-align: center; white-space: nowrap; border-bottom: black 1pt solid; border-left: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt; vertical-align: bottom"&gt;&lt;span style="font-size: 10pt"&gt;2023&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;458,215&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;span style="-sec-ix-hidden: hidden-fact-3"&gt;-&lt;/span&gt;&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;583,201&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;span style="-sec-ix-hidden: hidden-fact-4"&gt;-&lt;/span&gt;&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;479,376&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;617,643&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;137&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;17,368&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr style="vertical-align: bottom; background-color: #CCEEFF"&gt; &lt;td style="border-right: black 1pt solid; text-align: center; white-space: nowrap; border-bottom: black 1pt solid; border-left: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt; vertical-align: bottom"&gt;&lt;span style="font-size: 10pt"&gt;2022&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;128,001&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;666,490&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;(120,924)&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;783,197&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;400,741&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;430,932&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;114&lt;/span&gt;&lt;/td&gt; &lt;td style="white-space: nowrap; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; text-indent: 0pt"&gt;&#160;&lt;/td&gt; &lt;td style="border-right: black 1pt solid; border-bottom: black 1pt solid; padding: 0pt 0pt 9pt; white-space: nowrap; text-align: center; text-indent: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;15,673&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt; &lt;/table&gt;
&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0"&gt;&#160;&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0; text-indent: 0.5in"&gt;(1)&#160;&#160;&#160;&#160;&#160;&#160;&#160;Mr. Ronald L. Zimmerly served as Middlefield&#x2019;s
principal executive officer during 2024. The Non-PEO named executive officers for purposes of calculating the average non-PEO named executive
officer compensation in each applicable year are as follows: (i) for 2024, Michael C. Ranttila and Michael L. Cheravitch; (ii) for 2023,
Ronald L. Zimmerly and Michael C. Ranttila; and (iii) for 2022, Ronald L. Zimmerly and Donald L. Stacy. &lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0; text-indent: 0.5in"&gt;(2)&#160;&#160;&#160;&#160;&#160;&#160;&#160;The figure
presented for 2024 reflects the compensation actually paid to Mr. Zimmerly as Middlefield&#x2019;s principal executive officer. Column
(c) reflects additions and deductions of the following amounts from the summary compensation total for Mr. Zimmerly: (i) a gain of $633,902
to reflect the fair value at December 31, 2024 of all outstanding and unvested PSUs and RSUs granted to Mr. Zimmerly during 2024, (ii)
a loss of $32,443, which is the year over year change in fair value of outstanding and unvested equity awards granted to Mr. Zimmerly
in prior years, (iii) a gain of $15,561, to reflect the fair value of director stock grants awarded in 2024, and (iv) a loss of $6,137,
which is the change, as of the vesting date, in fair value of any awards granted to Mr. Zimmerly in any prior fiscal year for which all
applicable vesting conditions were satisfied at the end of or during the 2024 fiscal year.&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0; text-indent: 0.5in"&gt;(3) &#160;&#160;&#160;&#160;&#160;&#160;&#160;The figure
presented for 2024 reflects the following additions and deductions from the summary compensation totals for Non-PEO named executive officers:
(i) the $496,569 fair value at December 31, 2024 of outstanding and unvested PSUs and RSUs granted during 2024, (ii) a loss of $30,940
to reflect the year over year change in fair value at December 31, 2024 of outstanding and unvested equity awards in prior years, and
(iii) a loss of $17,802 to reflect the year over year change in fair value of equity awards granted in prior years that vested in 2024.&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0; text-indent: 0.5in"&gt;(4)&#160;&#160;&#160;&#160;&#160;&#160;&#160;Cumulative
total shareholder return is calculated in accordance with Item 402(v) of SEC Regulation S-K by dividing the sum of the cumulative amount
of dividends for the measurement period, assuming dividend reinvestment, and the difference between Middlefield&#x2019;s common share price
at the end and the beginning of the measurement period by Middlefield&#x2019;s common share price at the beginning of the measurement period.&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 0; text-indent: 0.5in"&gt;(5)&#160;&#160;&#160;&#160;&#160;&#160;&#160;Net income
as reported in our audited financial statements for the applicable year.&lt;/p&gt;</ecd:PvpTableTextBlock>
    <ecd:PeoTotalCompAmt contextRef="c1" decimals="0" id="ix_0_fact" unitRef="usd">1263438</ecd:PeoTotalCompAmt>
    <ecd:PeoActuallyPaidCompAmt contextRef="c1" decimals="0" id="ix_1_fact" unitRef="usd">1874321</ecd:PeoActuallyPaidCompAmt>
    <ecd:NonPeoNeoAvgTotalCompAmt contextRef="c0" decimals="0" id="ix_3_fact" unitRef="usd">581489</ecd:NonPeoNeoAvgTotalCompAmt>
    <ecd:NonPeoNeoAvgCompActuallyPaidAmt contextRef="c0" decimals="0" id="ix_4_fact" unitRef="usd">805402</ecd:NonPeoNeoAvgCompActuallyPaidAmt>
    <ecd:TotalShareholderRtnAmt contextRef="c0" decimals="0" id="ix_13_fact" unitRef="usd">123</ecd:TotalShareholderRtnAmt>
    <us-gaap:NetIncomeLoss contextRef="c0" decimals="-3" id="ixv-3597" unitRef="usd">15519000</us-gaap:NetIncomeLoss>
    <ecd:PeoTotalCompAmt contextRef="c3" decimals="0" id="ix_5_fact" unitRef="usd">458215</ecd:PeoTotalCompAmt>
    <ecd:PeoActuallyPaidCompAmt contextRef="c3" decimals="0" id="ix_6_fact" unitRef="usd">583201</ecd:PeoActuallyPaidCompAmt>
    <ecd:NonPeoNeoAvgTotalCompAmt contextRef="c5" decimals="0" id="ix_7_fact" unitRef="usd">479376</ecd:NonPeoNeoAvgTotalCompAmt>
    <ecd:NonPeoNeoAvgCompActuallyPaidAmt contextRef="c5" decimals="0" id="ix_8_fact" unitRef="usd">617643</ecd:NonPeoNeoAvgCompActuallyPaidAmt>
    <ecd:TotalShareholderRtnAmt contextRef="c5" decimals="0" id="ix_14_fact" unitRef="usd">137</ecd:TotalShareholderRtnAmt>
    <us-gaap:NetIncomeLoss contextRef="c5" decimals="-3" id="ixv-3603" unitRef="usd">17368000</us-gaap:NetIncomeLoss>
    <ecd:PeoTotalCompAmt contextRef="c6" decimals="0" id="ix_9_fact" unitRef="usd">128001</ecd:PeoTotalCompAmt>
    <ecd:PeoTotalCompAmt contextRef="c7" decimals="0" id="ix_10_fact" unitRef="usd">666490</ecd:PeoTotalCompAmt>
    <ecd:PeoActuallyPaidCompAmt contextRef="c6" decimals="0" id="ix_2_fact" unitRef="usd">-120924</ecd:PeoActuallyPaidCompAmt>
    <ecd:PeoActuallyPaidCompAmt contextRef="c7" decimals="0" id="ixv-3607" unitRef="usd">783197</ecd:PeoActuallyPaidCompAmt>
    <ecd:NonPeoNeoAvgTotalCompAmt contextRef="c8" decimals="0" id="ix_11_fact" unitRef="usd">400741</ecd:NonPeoNeoAvgTotalCompAmt>
    <ecd:NonPeoNeoAvgCompActuallyPaidAmt contextRef="c8" decimals="0" id="ix_12_fact" unitRef="usd">430932</ecd:NonPeoNeoAvgCompActuallyPaidAmt>
    <ecd:TotalShareholderRtnAmt contextRef="c8" decimals="0" id="ix_15_fact" unitRef="usd">114</ecd:TotalShareholderRtnAmt>
    <us-gaap:NetIncomeLoss contextRef="c8" decimals="-3" id="ixv-3611" unitRef="usd">15673000</us-gaap:NetIncomeLoss>
    <ecd:NamedExecutiveOfficersFnTextBlock contextRef="c0" id="ixv-3612">Mr. Ronald L. Zimmerly served as Middlefield&#x2019;s
principal executive officer during 2024. The Non-PEO named executive officers for purposes of calculating the average non-PEO named executive
officer compensation in each applicable year are as follows: (i) for 2024, Michael C. Ranttila and Michael L. Cheravitch; (ii) for 2023,
Ronald L. Zimmerly and Michael C. Ranttila; and (iii) for 2022, Ronald L. Zimmerly and Donald L. Stacy.</ecd:NamedExecutiveOfficersFnTextBlock>
    <ecd:PeoName contextRef="c0" id="ixv-3614">Mr. Ronald L. Zimmerly</ecd:PeoName>
    <ecd:CompActuallyPaidVsCoSelectedMeasureTextBlock contextRef="c0" id="ixv-2916">&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 10pt 0 0"&gt;&lt;b&gt;Relationship Between Pay and Performance. &lt;/b&gt;&lt;/p&gt;

&lt;p style="font: 10pt Times New Roman, Times, Serif; margin: 10pt 0 0; text-indent: 0.5in"&gt;The relationship between compensation actually
paid and Middlefield&#x2019;s financial performance over the three-year period shown in the preceding Pay Versus Performance Table is illustrated
in the following charts comparing PEO/NEO Compensation Actually Paid versus Total Shareholder Return (TSR) and Net Income.&lt;/p&gt;</ecd:CompActuallyPaidVsCoSelectedMeasureTextBlock>
    <ecd:CompActuallyPaidVsTotalShareholderRtnTextBlock contextRef="c0" id="ixv-2921">&lt;p style="text-align: center; font: 10pt Times New Roman, Times, Serif; margin-top: 10pt; margin-bottom: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;img alt="" src="image_002.gif" style="height: 295px; width: 577px"/&gt;&lt;/span&gt;&lt;/p&gt;</ecd:CompActuallyPaidVsTotalShareholderRtnTextBlock>
    <ecd:CompActuallyPaidVsNetIncomeTextBlock contextRef="c0" id="ixv-2926">&lt;p style="text-align: center; font: 10pt Times New Roman, Times, Serif; margin-top: 10pt; margin-bottom: 0pt"&gt;&lt;span style="font-size: 10pt"&gt;&lt;img alt="" src="image_001.jpg" style="height: 295px; width: 577px"/&gt;&lt;/span&gt;&lt;/p&gt;</ecd:CompActuallyPaidVsNetIncomeTextBlock>
    <dei:DocumentType contextRef="c0" id="hidden-fact-0">DEF 14A</dei:DocumentType>
    <ecd:PeoTotalCompAmt
      contextRef="c2"
      id="hidden-fact-1"
      unitRef="usd"
      xsi:nil="true"/>
    <ecd:PeoActuallyPaidCompAmt
      contextRef="c2"
      id="hidden-fact-2"
      unitRef="usd"
      xsi:nil="true"/>
    <ecd:PeoTotalCompAmt
      contextRef="c4"
      id="hidden-fact-3"
      unitRef="usd"
      xsi:nil="true"/>
    <ecd:PeoActuallyPaidCompAmt
      contextRef="c4"
      id="hidden-fact-4"
      unitRef="usd"
      xsi:nil="true"/>
    <dei:EntityCentralIndexKey contextRef="c0" id="ixv-3625">0000836147</dei:EntityCentralIndexKey>
    <dei:AmendmentFlag contextRef="c0" id="ixv-3626">false</dei:AmendmentFlag>
    <link:footnoteLink
      xlink:role="http://www.xbrl.org/2003/role/link"
      xlink:type="extended">
        <link:loc
          xlink:href="#ix_11_fact"
          xlink:label="ix_11_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#hidden-fact-3"
          xlink:label="hidden-fact-3"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_5_fact"
          xlink:label="ix_5_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_9_fact"
          xlink:label="ix_9_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_3_fact"
          xlink:label="ix_3_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_7_fact"
          xlink:label="ix_7_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#hidden-fact-1"
          xlink:label="hidden-fact-1"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_0_fact"
          xlink:label="ix_0_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_10_fact"
          xlink:label="ix_10_fact"
          xlink:type="locator"/>
        <link:footnote id="ix_0_footnote" xlink:label="ix_0_footnote" xlink:role="http://www.xbrl.org/2003/role/footnote" xlink:type="resource" xml:lang="en-US">Mr. Ronald L. Zimmerly served as Middlefield&#x2019;s
principal executive officer during 2024. The Non-PEO named executive officers for purposes of calculating the average non-PEO named executive
officer compensation in each applicable year are as follows: (i) for 2024, Michael C. Ranttila and Michael L. Cheravitch; (ii) for 2023,
Ronald L. Zimmerly and Michael C. Ranttila; and (iii) for 2022, Ronald L. Zimmerly and Donald L. Stacy.</link:footnote>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_11_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="hidden-fact-3"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_5_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_9_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_3_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_7_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="hidden-fact-1"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_0_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_10_fact"
          xlink:to="ix_0_footnote"
          xlink:type="arc"/>
        <link:loc
          xlink:href="#ix_2_fact"
          xlink:label="ix_2_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_6_fact"
          xlink:label="ix_6_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_1_fact"
          xlink:label="ix_1_fact"
          xlink:type="locator"/>
        <link:footnote id="ix_1_footnote" xlink:label="ix_1_footnote" xlink:role="http://www.xbrl.org/2003/role/footnote" xlink:type="resource" xml:lang="en-US">The figure
presented for 2024 reflects the compensation actually paid to Mr. Zimmerly as Middlefield&#x2019;s principal executive officer. Column
(c) reflects additions and deductions of the following amounts from the summary compensation total for Mr. Zimmerly: (i) a gain of $633,902
to reflect the fair value at December 31, 2024 of all outstanding and unvested PSUs and RSUs granted to Mr. Zimmerly during 2024, (ii)
a loss of $32,443, which is the year over year change in fair value of outstanding and unvested equity awards granted to Mr. Zimmerly
in prior years, (iii) a gain of $15,561, to reflect the fair value of director stock grants awarded in 2024, and (iv) a loss of $6,137,
which is the change, as of the vesting date, in fair value of any awards granted to Mr. Zimmerly in any prior fiscal year for which all
applicable vesting conditions were satisfied at the end of or during the 2024 fiscal year.</link:footnote>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_2_fact"
          xlink:to="ix_1_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_6_fact"
          xlink:to="ix_1_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_1_fact"
          xlink:to="ix_1_footnote"
          xlink:type="arc"/>
        <link:loc
          xlink:href="#ix_12_fact"
          xlink:label="ix_12_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_4_fact"
          xlink:label="ix_4_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_8_fact"
          xlink:label="ix_8_fact"
          xlink:type="locator"/>
        <link:footnote id="ix_2_footnote" xlink:label="ix_2_footnote" xlink:role="http://www.xbrl.org/2003/role/footnote" xlink:type="resource" xml:lang="en-US">The figure
presented for 2024 reflects the following additions and deductions from the summary compensation totals for Non-PEO named executive officers:
(i) the $496,569 fair value at December 31, 2024 of outstanding and unvested PSUs and RSUs granted during 2024, (ii) a loss of $30,940
to reflect the year over year change in fair value at December 31, 2024 of outstanding and unvested equity awards in prior years, and
(iii) a loss of $17,802 to reflect the year over year change in fair value of equity awards granted in prior years that vested in 2024.</link:footnote>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_12_fact"
          xlink:to="ix_2_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_4_fact"
          xlink:to="ix_2_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_8_fact"
          xlink:to="ix_2_footnote"
          xlink:type="arc"/>
        <link:loc
          xlink:href="#ix_13_fact"
          xlink:label="ix_13_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_15_fact"
          xlink:label="ix_15_fact"
          xlink:type="locator"/>
        <link:loc
          xlink:href="#ix_14_fact"
          xlink:label="ix_14_fact"
          xlink:type="locator"/>
        <link:footnote id="ix_3_footnote" xlink:label="ix_3_footnote" xlink:role="http://www.xbrl.org/2003/role/footnote" xlink:type="resource" xml:lang="en-US">Cumulative
total shareholder return is calculated in accordance with Item 402(v) of SEC Regulation S-K by dividing the sum of the cumulative amount
of dividends for the measurement period, assuming dividend reinvestment, and the difference between Middlefield&#x2019;s common share price
at the end and the beginning of the measurement period by Middlefield&#x2019;s common share price at the beginning of the measurement period.</link:footnote>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_13_fact"
          xlink:to="ix_3_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_15_fact"
          xlink:to="ix_3_footnote"
          xlink:type="arc"/>
        <link:footnoteArc
          xlink:arcrole="http://www.xbrl.org/2003/arcrole/fact-footnote"
          xlink:from="ix_14_fact"
          xlink:to="ix_3_footnote"
          xlink:type="arc"/>
    </link:footnoteLink>
</xbrl>
