Two terrorists were killed by security forces in an encounter in Sopore area of Baramulla district of Jammu and Kashmir.