Lima is generally safe for tourists as long as you stay in the main visitor areas and take normal big-city precautions. Most travelers have no problems when they avoid poorly lit streets at night, keep valuables out of sight, and use ride-hailing apps instead of street taxis. The best places to stay are Miraflores (most popular for tourists, ocean views, restaurants, shopping, and good security), Barranco (artsy, bohemian, great nightlife and cafés, safe in main areas), and San Isidro (upscale, quiet, very safe, ideal for a relaxed stay). Areas like the Historic Center are fine during the day but less recommended at night, while districts such as Callao (outside the airport area) are best avoided. Overall, Lima is a rewarding destination if you choose the right neighborhood and stay aware.
Recommended places to stay:
Miraflores
San Isidro
Barranco
Do NOT visit these neighborhoods:
San Juan de Lurigancho
Ventanilla
San Martin de Porres
Callao (Airport is Safe)
Comas
Villa El Salvador
Villa Maria del Triunfo