Insulating your hot water pipes from your tankless water heater reduces heat loss and can raise water temperature 2ºF–4ºF hotter than not insulated pipes can deliver, allowing for a lower water temperature setting. You also won't have to wait as long for hot water when you turn on a faucet or showerhead, which helps conserve water.
Insulate all accessible hot water pipes, especially within 3 feet of the tankless water heater. It's also a good idea to insulate the cold water inlet pipes for the first 3 feet as well.
Use quality pipe insulation wrap, or neatly tape strips of fiberglass insulation around the pipes. Pipe sleeves made with polyethylene or neoprene foam are the most commonly used insulation. Match the pipe sleeve's inside diameter to the pipe's outside diameter for a snug fit. Place the pipe sleeve so the seam will be face down on the pipe. Tape, wire, or clamp (with a cable tie) it every foot or two to secure it to the pipe. If you use tape, some recommend using acrylic tape instead of duct tape.
On gas tankless water heaters, keep insulation at least 6 inches from the flue. If pipes are within 8 inches of the flue, your safest choice is to use fiberglass pipe-wrap (at least 1-inch thick) without a facing. You can use either wire or aluminum foil tape to secure it to the pipe.