# Asterisk PJSIP: How to force using domain name instead of IP address for TO Header

**URL:** <https://community.asterisk.org/t/asterisk-pjsip-how-to-force-using-domain-name-instead-of-ip-address-for-to-header/71898>\
**Category:** Asterisk Endpoints\
**Created:** [September 6, 2017, 9:35am UTC](https://community.asterisk.org/t/asterisk-pjsip-how-to-force-using-domain-name-instead-of-ip-address-for-to-header/71898 "2017-09-06T09:35:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dendene](https://avatars.discourse-cdn.com/v4/letter/d/aeb1de/32.png) [@dendene](https://community.asterisk.org/u/dendene)\
**Post date:** [September 6, 2017, 9:35am UTC](https://community.asterisk.org/t/asterisk-pjsip-how-to-force-using-domain-name-instead-of-ip-address-for-to-header/71898/1 "2017-09-06T09:35:45Z")

</div>

I have a SIP message sent by asterisk like this:

```auto
MESSAGE sip:DEST@192.168.0.141:43467 SIP/2.0
Via: SIP/2.0/TLS 194.206.195.58:5061;branch=z9hG4bKd289b07ce2750aeb2fed3a94db29373e
Via: SIP/2.0/UDP 10.42.0.70:5060;rport;branch=z9hG4bKPj697b6f22-49f0-4c31-bfd3-c7be3e3a44b7
From: <sip:SRC@mydomain.com>;tag=dee4bce6-1bfe-42fc-8664-06a9fbc9c3fc
To: <sip:DEST@10.42.0.10>
Contact: <sip:DEST@194.206.195.58:5061;transport=TLS>
Call-ID: e5bc8004-0514-42d5-9391-470bf90d02fe
...

```

For **FROM header** , i use the field from\_domain into ps\_endpoints table, but for **To header** i cannot see where to fix using domain name instead of the IP address.

Thank’s in advance
