<PAGE>

                                                                   EXHIBIT 10(g)

                              GLACIER BANCORP, INC.
                           DEFERRED COMPENSATION PLAN
               (AS AMENDED AND RESTATED EFFECTIVE JANUARY 1, 2005)

      Glacier Bancorp, Inc. (the "Company"), a Montana corporation, by
resolution of its Board of Directors dated ______________, 2005, hereby amends
and restates its Deferred Compensation Plan (the "Plan"), effective January 1,
2005,for a determined class (the "Class") consisting of its directors and
certain other officers and key employees, as herein provided. This Plan is a
nonqualified deferred compensation plan which is unfunded and is maintained
primarily for the purpose of providing deferred compensation for a select group
of management or highly compensated employees and non-employee directors of the
Company.

                   ARTICLE I - DESIGNATED CLASS; PARTICIPATION

      The Class eligible to participate in the Plan shall be limited to members
of the Board of Directors ("Board") of the Company (including the Chairman), the
Company's President, and such other officers or key employees of the Company as
the Board may identify by resolution as being eligible for participation in the
Plan. However, an individual within the Class shall become a "Participant" in
the Plan only if the individual first enters into a properly completed "Deferral
Election Form" (substantially in the form attached hereto as Exhibit A), and
"Distribution Election Form" (substantially in the form attached hereto as
Exhibit B). These election forms shall be subject to any revisions that the
Board may approve in its discretion from time to time for use, after written
notice to Participants, on a prospective basis for future elections.

                          ARTICLE II - DEFERRED AMOUNTS

      Deferred amounts shall be credited by the Company at the end of each
calendar quarter beginning after 2004, in accordance with the terms of the Plan
as amended and restated herein, and the Deferral Election Form entered into
between Participants and the Company, as provided for in Article I hereof. The
funds so deferred quarter-annually shall be credited by the Company to a
bookkeeping account ("Account") in the name of each Participant, according to
the terms of the Participant's Deferral Election Form. Each Participant's
Account shall be credited as of January 1, 2005, with the balance credited to
the Participant's Account as of December 31, 2004 (pursuant to the terms of the
Plan prior to this amendment and restatement).

      In addition to the amounts credited to each Participant's Account as of
January 1, 2005, and quarter-annually thereafter, the Company shall adjust each
Participant's Account as of the end of each calendar year beginning after 2004
to reflect a rate of return (positive or negative) equal to fifty (50%) percent
of return-on-average equity of common stock issued by Glacier Bancorp, Inc. as
of December 31 of the Company's most recently-completed fiscal year.

      The value of each Participant's Account as determined as of a given date
under this Article, plus any amounts subsequently allocated thereto under this
Article, and less any amounts distributed or withdrawn under Article IV shall
remain the value thereof for all purposes of the Plan until the Account is
revalued hereunder.

<PAGE>

                 ARTICLE III - ANTI-ALIENATION; PARTICIPANTS TO
                               BE UNSECURED CREDITORS

      (a) A Participant's interest in the Plan shall not be subject in any
manner to anticipation, alienation, sale, transfer, assignment, pledge,
encumbrance, or charge; and the Company shall not be obligated to make any
payments to persons other than as specifically provided in the Plan. Such
payments shall be made in the regular course of business from the general funds
of the Company as they become due, except that such payments may be made from
any trust ("Trust") that the Company may establish in its discretion in
accordance with the terms of Article VII below.

      (b) Neither the Participants, nor their beneficiaries, nor any other
person or persons having or claiming a right to payments hereunder or to any
interest in the Plan shall have a secured claim against the assets of the
Company, and such persons shall rely solely on the unsecured promise of the
Company for the payment of any benefits pursuant to the Plan. Nothing herein
shall be construed to give any person any right, title, interest, or claim in or
to any specific asset, fund, reserve, account, or property of any kind
whatsoever owned by them or in which it may have any right, title or interest
now or in the future; but such persons shall have the right to enforce his or
her claim against the Company in the same manner as any unsecured creditor.

                      ARTICLE IV - PAYMENTS TO PARTICIPANTS

      (a) A Participant's Account shall be paid in accordance with the elections
made in the particular Distribution Election Form or Forms applicable to the
deferred amounts. Each distribution election shall be made on or before the
effective date of the Deferral Election Form to which the Distribution Election
Form relates. A Participant may change one or more distribution elections by -

            (i) providing the Board with a new Distribution Election Form at
      least one year before the date on which distributions are otherwise
      scheduled to commence pursuant to the Participant's otherwise applicable
      election from the choices set forth under Article IV(b) hereof, and

            (ii) selecting a new distribution schedule that is allowable under
      Article IV(b) hereof, that specifies the portion of the Participant's
      Account to which it relates, and that defers the commencement of
      distributions by at least five years from the originally scheduled
      commencement date.

      (b) A Participant may elect in his or her Distribution Election Form to
have the amounts deferred pursuant to the Participant's Deferral Election Form,
and any earnings credited thereto pursuant to Article II above, distributed
beginning during the first 15 days of January of the first to occur of either --

                  (i) the calendar year immediately following the year in which
            the Participant ceases service with the Company, or

                  (ii) the later of (I) the calendar year immediately following
            the year in which the Participant ceases service with the Company,
            and (II) a specified date designated by the Participant, but not
            later than the year in which the Participant will attain age 72); or

<PAGE>

                  (iii) the year in which the Participant attains age 72; or

                  (iv) the ___ (not more than fifth) anniversary of the date on
            which the Participant ceases service with the Company; or

                  (v) a Change in Control.

Notwithstanding a Participant's election from the above choices, the Company
shall suspend payments until the date six (6) months after the date on which the
Participant terminates service with the Company if the Board (acting without
voting or participation by the Participant) determines that earlier payment
would violate Section 409A(a)(2)(B)(i) of the Internal Revenue Code of 1986, as
amended (the "Code").

      (c) A Participant may further elect in his or her Distribution Election
Form to have the amounts deferred pursuant to the associated Deferral Election
Form, and any earnings credited thereto pursuant to Article II above,
distributed either --

            (i) in a lump sum; or

            (ii) in substantially equal annual payments over period of ___ years
            (not to exceed 10 years from the date the Participant ceases service
            with the Company).

      (d) If a Participant should die before receiving all deferred compensation
benefits payable hereunder, then such payment(s) shall be made to the
beneficiary designated by the Participant in his or her Agreement. If the
beneficiary has predeceased the Participant or survives the Participant but then
dies before all benefits payable hereunder have been paid, then the aggregate
benefits then unpaid shall be paid over to the beneficiary's estate, in a lump
sum, on the 90th day following the date of the Participant's death.

                   ARTICLE V - AMOUNT OF DEFERRED COMPENSATION

      A Participant who is a member of the Board and who is not an employee of
the Company may elect on a Deferral Election Form to have any portion of his or
her director's fees deferred under this Plan. Any other Participant may elect on
a Deferral Election Form to defer annually under the Plan up to 50% of his or
her salary to be earned in the calendar year and otherwise become payable in
cash from the Company, and up to 100% of any such cash bonuses. Any election
made with respect to the amount to be deferred, and the timing and method of
payment of benefits hereunder, shall be made prior to the beginning of the
calendar year in which the services giving rise to the amounts deferred are
earned, and shall take effect on the January 1st following such election;
provided that (i) a Participant may at any time elect to cease future deferrals;
and (ii) an individual who first becomes eligible to participate in the Plan
during a calendar year may deliver to the Board his or her executed Deferral
Election Form and Distribution Election Form within thirty (30) days of becoming
eligible for Plan participation, in which event the Participant's elections
shall apply only to compensation that would otherwise be payable for services
performed during the remainder of such calendar year.

                       ARTICLE VI - CHANGES TO AGREEMENTS

      Except as otherwise specifically provided in Article IV(a) relating to
changes to

<PAGE>

distribution elections and Article V relating to the cessation of deferrals, all
elections made under this Plan shall be irrevocable with respect to amounts
deferred pursuant to the terms and conditions of Deferral Election Forms and
Distribution Election Forms. A Participant may nevertheless at any time and from
time to time change the beneficiary designated in paragraph 4 of the
Distribution Election Form. A Participant may at any time file election forms
which supersede prior election forms as to amounts deferred on or after the
January 1st that follows execution of the superseding election forms, provided
that the prior election forms shall nevertheless continue in full force and
effect, and be irrevocable, with respect to the time and manner of payment of
amounts deferred prior to the effective date of the superseding election forms.

                         ARTICLE VII - CHANGE IN CONTROL

      At any time before, but not more than five business days after, a Change
in Control (as defined under the Company's 2005 Stock Incentive Plan), the
Company shall contribute to a Trust associated with the Plan an amount
equivalent to the aggregate amount payable to Participants, which amount would
then be used to assist the Company in making eventual payment to Participants
under the terms and conditions of the Plan. The Trust and any assets held
therein to assist the Company in meeting its obligations under the Plan and
shall conform to the provisions of the model trust, as described in Revenue
Procedure 92-64 (or any successor thereto). It is the intention of the parties
that the Plan and the arrangements associated therewith (including the Trust) be
unfunded for tax purposes and for purposes of Title I of the Employee Retirement
Income Security Act of 1974, as amended.

                     ARTICLE VIII - MISCELLANEOUS PROVISIONS

      (a) The Board shall be responsible for the management and control of the
operation and administration of the Plan, including any and all interpretations
and decisions pertaining to the granting or denial of benefits, claims, and any
and all interpretations and decisions pertaining to the review or denial of
benefit claims. The Plan shall inure to the benefit of the Participants and
shall be binding upon the Company, its successors and assigns. The Board shall
have discretion to amend or terminate the Plan at any time and from time to
time, provided that no change in the Plan which adversely affects any
Participant (or beneficiary collecting benefits) shall be made without the
written consent of the Participant (or beneficiary) so affected.

      (b) All references herein to "the Company" shall be deemed to refer with
equal force and effect both to any wholly-owned subsidiary of the Company, and
to any corporate or other successor of the Company which shall acquire, directly
or indirectly, by merger, consolidation, purchase, or otherwise, all or
substantially all of the assets of the Company.

      (c) In the event any parts of the Plan are found to be void, the remaining
provisions of this Plan shall, nevertheless, be binding with the same effect as
though the void parts were deleted.

      (d) The Secretary of the Company shall maintain a copy of the Plan and any
amendments thereto.

      (e) All distributions under the Plan shall be subject to reduction by the
Company for all amounts that the Company is required to withhold under federal,
state or local tax law.

      (f) PARTICIPANTS ARE SOLELY RESPONSIBLE AND LIABLE FOR THE SATISFACTION OF
ALL TAXES AND

<PAGE>

PENALTIES (INCLUDING ANY TAXES ARISING UNDER SECTION 409A OF THE CODE) THAT MAY
ARISE IN CONNECTION WITH THEIR PLAN PARTICIPATION AND COLLECTION OF PAYMENTS
FROM THEIR ACCOUNTS. THE COMPANY SHALL NOT HAVE ANY OBLIGATION TO INDEMNIFY OR
OTHERWISE HOLD ANY PARTICIPANT HARMLESS FROM ANY OR ALL OF SUCH TAXES. THE BOARD
SHALL, HOWEVER, SHALL HAVE THE DISCRETION TO ADMINISTER THE PLAN, TO MODIFY
DEFERRAL AND DISTRIBUTION ELECTION FORMS, AND TO UNILATERALLY MODIFY ANY SUCH
FORM IN A MANNER THAT (i) CONFORMS IT WITH THE REQUIREMENTS OF SECTION 409A OF
THE CODE, OR (ii) VOIDS ANY PARTICIPANT'S ELECTION, OR PROVISION WITHIN AN
ELECTION, TO THE EXTENT IT WOULD VIOLATE SECTION 409A OF THE CODE.

      IN ADDITION, IF THE BOARD DETERMINES THAT A PAYMENT OF PLAN BENEFITS TO A
PARTICIPANT WOULD VIOLATE SECTION 409A OF THE CODE, THE BOARD SHALL MAKE SUCH
PAYMENT ONLY AND AUTOMATICALLY UPON THE EARLIEST DISTRIBUTION EVENT THAT IS
PERMISSIBLE UNDER SECTION 409A OF THE CODE, SUBJECT TO ANY VALID SECOND ELECTION
TO DEFER THAT A PARTICIPANT MAKES PURSUANT to Article IV(a) OF THE PLAN. THE
ADMINISTRATOR SHALL HAVE THE SOLE DISCRETION TO INTERPRET THE REQUIREMENTS OF
THE CODE, INCLUDING SECTION 409A, FOR PURPOSES OF THE PLAN.

                     ARTICLE IX - SPECIAL ELECTION FOR 2005

      For calendar year 2005, any Participant with a positive Account as of
December 31, 2004 may make either or both of the following elections using the
form attached hereto as Exhibit C:

      (a) to terminate participation in the Plan with respect to all or part of
the value of the Participant's Account on December 31, 2004; and/or

      (b) to cancel a deferral election that would otherwise be effective in
2005 with regard to amounts deferred or to be deferred in 2005.

      Any amounts subject to an election on Exhibit C shall be paid to the
Participant in 2005 and shall be includible in income of the Participant for
2005.

                           ARTICLE X - EFFECTIVE DATE

      The amended and restated Plan shall become effective January 1, 2005.

<PAGE>

                                    EXHIBIT A
                              GLACIER BANCORP, INC.
                         2005 DEFERRED COMPENSATION PLAN

                             ----------------------

                             DEFERRAL ELECTION FORM

                             ----------------------

      AGREEMENT, made this __ day of ________, ____, by and between me,
(_______________), in my individual capacity as a participant or potential
participant in the Glacier Bancorp, Inc. 2005 Deferred Compensation Plan (the
"Plan"), and Glacier Bancorp, Inc. (the "Company"), in its settlor capacity as
sponsor of the Plan. The parties agree that any term that begins herein with
initial capital letters shall have the special meaning defined in the plan,
unless the context clearly requires otherwise.

      WHEREAS, I understand that terms herein that begin with initial capital
letters will have the defined meaning set forth in the Plan (unless the context
clearly indicates a different meaning).

      NOW THEREFORE, it is mutually agreed as follows:

      1. By the execution hereof, I agree to participate in the Plan upon the
terms and conditions set forth therein, and, in accordance therewith, make the
elections set forth herein effective -

      ___   on the January 1st that follows the Board's acceptance of my
            Deferral Election Form and Distribution Election Form.

      ___   on the first day of the next calendar month, but only if the Board
            accepts my Deferral Election Form and Distribution Election Form
            within the 30-day period after I first become eligible for Plan
            participation.

      2. For the duration of this election (as determined under Section 3
below), I hereby elect to defer the receipt of the following percentage of cash
bonus and director fees that the Company will withhold and credit to my Account
pursuant to the Plan:

      ___%  of any salary that I receive.

      ___%  of any cash bonuses that I receive.

      ___%  of any director fees that I receive.

      3. I recognize and agree that this election will remain in effect
indefinitely, until the earlier of (a) the date on which my service with the
Company terminates, (b) the date on which the Board receives a written notice in
which I terminate this election, and (c) the effective date of a superseding
election made using election forms acceptable to the Board.

      4. By the execution hereof, I further recognize and agree to participate
in the Plan upon the terms and conditions set forth therein, including but not
limited to the following terms:

<PAGE>

      (a)   This election is irrevocable with respect to any cash bonus,
            director fee or salary that is deferred during the term of this
            agreement.

      (b)   Unless made in bad faith, any decisions of the Administrator with
            respect to the operation, interpretation, or administration of the
            Plan or my Account will be final and binding on me and all other
            interested parties.

      IN WITNESS WHEREOF, the parties hereto have hereunto set their hands the
day and year first above-written.

Witnessed by:                         PARTICIPANT

___________________________           ________________________________

Witnessed by:                         GLACIER BANCORP, INC.

__________________________            By_____________________________________
                                        A member of the Board of Directors

<PAGE>

                                    EXHIBIT B
                              GLACIER BANCORP, INC.
                         2005 DEFERRED COMPENSATION PLAN

                           --------------------------

                           DISTRIBUTION ELECTION FORM

                           --------------------------

      AGREEMENT, made this __ day of ________, ____, by and between me,
(_______________), in my individual capacity as a participant or potential
participant in the Glacier Bancorp, Inc. 2005 Deferred Compensation Plan (the
"Plan"), and Glacier Bancorp, Inc. (the "Company"), in its settlor capacity as
sponsor of the Plan. The parties agree that any term that begins herein with
initial capital letters shall have the special meaning defined in the plan,
unless the context clearly requires otherwise.

      NOW THEREFORE, it is mutually agreed as follows:

      1. Timing of Payment. If I elected to receive my Accounts in substantially
equal annual payments in Section 1, I direct that my Accounts begin to be
distributed to me as follows (but not earlier than six (6) months after I cease
service with the Company):

            [ ]   on the January 1st that next follows the date that is ___
                  years (not more than 10) after I cease service service with
                  the Company.

            [ ]   on the ____ (not more than 5th) anniversary after I cease
                  service with the Company.

            [ ]   on the first date of the month next following my 72nd
                  birthday.

            [ ]   the later of (I) the calendar year immediately following the
                  year in which I cease service with the Company, and (II) the
                  following date: ___________ ___, _____ (not later than the
                  date on which the Participant will attain age 72).

            [ ]   On the date of a Change in Control.

I recognize and agree that notwithstanding my election above, I shall not
receive any distribution from the Plan within the six-month period following the
date on which I cease service with the Company if the Board acting without my
voting or participation determines that earlier payment would violate Section
409A(a)(2)(B)(i) of the Code.

      2. Form of Payment Generally. By the execution hereof, I agree to
participate in the Plan, upon the terms and conditions set forth therein, and,
in accordance therewith, elect to have my Account distributed in cash or in the
form of a check as follows:

            [ ]   in a lump sum.

<PAGE>

            [ ]   in substantially equal annual payments over a period of ___
                  years (not to exceed 10 years from the date my service with
                  the Company terminates).

      3. Form of Payment to Beneficiary. In the event of my death, my Account
shall be distributed --

            [ ]   in one lump sum payment within ninety (90) days following my
                  death.

            [ ]   in accordance with the payment schedule selected in Sections 1
                  and 2 hereof (with payments made as though I survived to
                  collect all benefits, and as though I terminated service on
                  the date of my death, if payments had not already begun).

      4. Designation of Beneficiary. In the event of my death before I have
collected all of the benefits payable under the Plan, I hereby direct that any
remaining benefits payable under the Plan be distributed to the beneficiary or
beneficiaries designated under subparagraphs a and b of this Section 4 in the
manner elected pursuant to Section 3 above:

      a. Primary Beneficiary. I hereby designate the person(s) named below to be
my primary beneficiary and to receive the balance of any unpaid benefits under
the Plan.

<TABLE>
<CAPTION>
      Name of           Social Security                       Percentage of
Primary Beneficiary         Number         Mailing Address    Death Benefit
-------------------     ---------------    ---------------    -------------
<S>                     <C>                <C>                <C>
                                                                    %

                                                                    %
</TABLE>

      b. Contingent Beneficiary. In the event that the primary beneficiary or
beneficiaries named above are not living at the time of my death, I hereby
designate the following person(s) to be my contingent beneficiary for purposes
of the Plan:

<TABLE>
<CAPTION>
        Name of         Social Security                       Percentage of
Contingent Beneficiary      Number         Mailing Address    Death Benefit
----------------------  ---------------    ---------------    -------------
<S>                     <C>                <C>                <C>
                                                                    %

                                                                    %
</TABLE>

      5.    Effect of Election. The elections made in paragraphs 1 and 2 hereof
            shall apply -

            [ ]   to any deferred compensation that is deferred pursuant to the
                  deferral election to which this election relates.

            [ ]   to the entire value of my Account, provided that these
                  elections may only be changed at least one year in advance of
                  the earliest date on which payments would otherwise commence
                  pursuant to paragraph 2 hereof, and may only

<PAGE>

                  be changed pursuant to an election that conforms with the
                  requirements set forth in Article IV(a) of the Plan.

      With respect to the elections in paragraphs 3 and 4 hereof, I recognize
that I may, by submitting an effective superseding Distribution Election Form at
any time and from time to time, prospectively change the beneficiary designation
and the manner of payment to a Beneficiary. Such elections shall, however,
become irrevocable upon my death.

      6. Mutual Commitments. The Company agrees to make payment of all amounts
due to me in accordance with the terms of the Plan and the elections I make
herein. I agree to be bound by the terms of the Plan, as in effect on the date
hereof or properly amended hereafter.

      7. Tax Responsibility. I recognize and agree that I am solely responsible
for the satisfaction of any taxes that may arise under the Plan, (including any
taxes arising under Sections 409A or 4999 of the Code), and that neither the
Company nor any of its employees, officers, directors, or service providers has
any right or obligation to provide me with tax planning advice, or to structure
the terms of the Plan or any payments to me in a manner that mitigates my tax
liability. It being understood that I should seek and rely on personal,
professional tax advice with respect to the Plan and its tax consequences to me,
I agree to hold each and every one of them harmless against all loss of any kind
(including attorneys fees they incur) with respect to any claim that I make with
respect to my participation in the Plan and my collection of benefits from the
Plan.

      IN WITNESS WHEREOF, the parties hereto have hereunto set their hands the
day and year first above-written.

Witnessed by:                          PARTICIPANT

________________________________       ________________________________

Witnessed by:                          GLACIER BANCORP, INC.

________________________________       By____________________________________
                                         A member of the Board of Directors

<PAGE>

                                    EXHIBIT C
                              GLACIER BANCORP, INC.
                         2005 DEFERRED COMPENSATION PLAN

                   -------------------------------------------

                   SPECIAL DISTRIBUTION ELECTION FORM FOR 2005

                   -------------------------------------------

      AGREEMENT, made effective this __ day of ____________, 2005, by and
between me, (_______________________), in my individual capacity as a
participant or potential participant in the Glacier Bancorp, Inc. 2005 Deferred
Compensation Plan (the "Plan"), and Glacier Bancorp, Inc. (the "Company"), in
its settlor capacity as sponsor of the Plan. The parties agree that any term
that begins herein with initial capital letters shall have the special meaning
defined in the plan, unless the context clearly requires otherwise.

      WHEREAS, I participated in the Plan prior to January 1, 2005, had a
positive Account as of December 31, 2004, and am currently a participant in the
Plan;

      WHEREAS, value of my Account was $___________ as of _______________ ___,
2005;

      WHEREAS, in accordance with Article IX of the Plan, I desire to collect
the amount of my Account designated below, and I understand the terms,
conditions, and tax consequences arising from my election herein;

      WHEREAS, I recognize and agree that, by making this election, the entire
value of my Account will become subject to the terms, conditions, and potential
imposition of taxes that are provided for in Section 409A of the Code.

      NOW THEREFORE, it is mutually agreed as follows:

      1. Form of Payment Generally. By the execution hereof, I elect volntarily
to terminate participation in the Plan with respect $_______________ that is
currently credited to my Account.

      2. Taxable Income in 2005. I recognize and agree that the payment that the
Company makes to me pursuant to Section 1 above will be made in 2005, will
reduce the value of my Account, and will be reported to me as taxable income for
services rendered in 2005, and will be subject to applicable employment taxes
and tax withholding.

      3. Tax Responsibility. I recognize and agree that I am solely responsible
for the satisfaction of any federal, state, or local taxes that may arise under
the Plan, (including any taxes arising under Sections 409A or 4999 of the Code),
and that neither the Company nor any of its employees, officers, directors, or
service providers has any right or obligation to provide me with tax planning
advice, or to structure the terms of the Plan or any payments to me in a manner
that mitigates my tax liability.

      It being understood that I should seek and rely on personal, professional
tax advice with respect to the Plan and its tax consequences to me, I agree to
hold each and every one of them harmless against all loss of any kind (including
attorneys fees they incur) with respect to any claim that I make with

<PAGE>

respect to my participation in the Plan and my collection of benefits from the
Plan.

      4. I further understand that the representations, covenants, and
commitments set forth herein are irrevocable and binding, and that this
Agreement, and the Plan, set forth the entire agreement between the parties with
respect to any subject matter covered herein.

    ACCEPTED AND AGREED TO this ________ day of ______________, 20___.

                      Participant's Signature: __________________________

                      Participant's Name (printed): _________________________

    ACCEPTED AND AGREED TO this ________ day of ______________, 20___.

                      Glacier Bancorp, Inc.

                      By __________________________________________________
                      A duly authorized Member of the Board of Directors