That could be weeks away and rates could change unfavorably just as they have in recent days. Shop around for both the terms of the lock contract and its cost. Some lenders may charge you an upfront, nonrefundable fee should you withdraw your application, if your credit is denied, or if for some other reason you don't close the loan. Others might charge the fee at settlement. The fee might be a flat fee, a percentage of the mortgage amount, a fraction of a percentage point or a higher interest rate.
Some lenders offer the service at no cost.
The lock-in period should be long enough to allow for settlement, contingencies imposed by the lender or purchase contract and all other factors that could delay the process. Most range from 15 to 60 days. Anything longer could be cost prohibitive. Consider all factors that could delay your settlement, including the time it will take you to provide requested materials about your financial condition, unanticipated construction delays on a new house and the like. Right now mortgage lenders offering competitive rates are flooded with mortgage applications.