I'm installing a new dishwasher. I would like to go with a plug and outlet even though the old one was hardwired into the house. What do I do to take care of the hardwire line?
Purchase an appliance cord, at least 6' long. Route the power cable from the house for the dishwasher into the the under sink space. Install a electrical box and conventional receptacle on this power line. Fix it to the back wall of the sink base. Route the cord from the dish washer into the sink base together with the water lines. Plug this cord into the new receptacle. P.
The hardwired line could be used to feed the receptacle. No point to running a new circuit if that one is an individual circuit.
Regardless of whether you use a receptacle or not, the outlets (not receptacles) on the circuit supplying the dishwasher are now required to be protected by GFCI.
From the 2014 and 2017 National Electrical Code:
210.8(D) Kitchen Dishwasher Branch Circuit. GFCI protection shall be provided for outlets that supply dishwashers installed in dwelling unit locations.
So, you can either buy a GFCI receptacle (cheaper solution) or a GFCI breaker for the circuit that it is connected to.
Good luck with your project!