Yes, you can legally live in Japan while working remotely if you hold a Japan Digital Nomad Visa. This visa allows you to stay in the country for up to 6 months and continue your online work for overseas employers or clients. However, you are not permitted to work for Japanese companies or earn income from within Japan.