Yes it's fine to have them both in one box and if your door bell button outside is lighted it will be hot to the touch because of the bulb inside but should not be hot enough to burn you if it is then you need to replace the transformer hope this was ...