Depending on the level of damage found, removing and replacing the air conditioner cord plug head is the best way to repair the cord on an AC window unit. Power cords with multiple tears and cuts in the rubber casing or damaged electrical wires should be replaced instead of repaired.
Unplug the window air conditioner unit before inspecting the power cord. Inspect the entire power cord by removing the power cord plate, along with the screws that hold the cord in place. Check the power cord for tears and cracks. Use wire cutters to remove the plug head and wire strippers to remove a section of rubber covering the electrical wiring. Insert the exposed electrical wiring into the new plug head, and snap it into place. Apply a thin layer of sealant around the bottom of the plug head to prevent future damage.
Replace the entire cord with a new power cord that has the same voltage as the old power cord. Refer to the user's manual or inspect the cord for voltage information. Attach the new cord by inserting it into the air conditioner unit and reattaching all screws. Reattach the power cord plate, and position the unit in the window. Turn the unit on to make sure it is functioning properly.