The payment function in Excel can be used to calculate monthly loan payments. It requires entering the loan amount, interest rate, term of the loan in years, and leaves the monthly payment cell blank to calculate. To use it, one opens Excel, creates a title over columns for loan amount, interest rate, term, and monthly payment. The payment function is selected from the function library, and the rate and number of periods cells are referenced to populate the monthly payment automatically. In summary, the payment function simplifies monthly loan calculation in Excel without recalculating when inputs change.