My friend wants me to pray to the devil with him. In doing so, would I be going to hell for speaking with the devil?
Praying to the devil is playing with fire (no pun intended). Satan is a formidable enemy, far surpassing our own natural strength (Ephesians 6:12). For that reason, the Bible instructs us to “Resist the devil” (James 4:7). Praying to Satan is not resisting him. Praying to Satan could certainly lead to a falling away from Jesus and an eternal association with Satan in hell.
I would strongly encourage you to reject your friend’s invitation to pray to Satan. Do also warn your friend about this dangerous activity. If you want to say anything to the devil, I would encourage you to say what Jesus said to him, “Away from me, Satan!” (Matthew 4:10)