diff --git a/src/php/ext/grpc/call.c b/src/php/ext/grpc/call.c
index b67bae75682f6b46aa0fb8abbc45ff59014f1245..1f76c7359d45bf371c415ceb4ccbdfab295431e3 100644
--- a/src/php/ext/grpc/call.c
+++ b/src/php/ext/grpc/call.c
@@ -472,6 +472,16 @@ cleanup:
   RETURN_DESTROY_ZVAL(result);
 }
 
+/**
+ * Get the endpoint this call/stream is connected to
+ * @return string The URI of the endpoint
+ */
+PHP_METHOD(Call, getPeer) {
+  wrapped_grpc_call *call =
+      (wrapped_grpc_call *)zend_object_store_get_object(getThis() TSRMLS_CC);
+  RETURN_STRING(grpc_call_get_peer(call->wrapped), 1);
+}
+
 /**
  * Cancel the call. This will cause the call to end with STATUS_CANCELLED if it
  * has not already ended with another status.
@@ -485,7 +495,9 @@ PHP_METHOD(Call, cancel) {
 static zend_function_entry call_methods[] = {
     PHP_ME(Call, __construct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_CTOR)
     PHP_ME(Call, startBatch, NULL, ZEND_ACC_PUBLIC)
-    PHP_ME(Call, cancel, NULL, ZEND_ACC_PUBLIC) PHP_FE_END};
+    PHP_ME(Call, getPeer, NULL, ZEND_ACC_PUBLIC)
+    PHP_ME(Call, cancel, NULL, ZEND_ACC_PUBLIC)
+    PHP_FE_END};
 
 void grpc_init_call(TSRMLS_D) {
   zend_class_entry ce;
diff --git a/src/php/ext/grpc/channel.c b/src/php/ext/grpc/channel.c
index b8262db162bf48350cd0d05919904d099aff6b1f..fe69fa5e29ae4ede314b3eef297e2e21b18f35fb 100644
--- a/src/php/ext/grpc/channel.c
+++ b/src/php/ext/grpc/channel.c
@@ -194,6 +194,16 @@ PHP_METHOD(Channel, __construct) {
   memcpy(channel->target, override, override_len);
 }
 
+/**
+ * Get the endpoint this call/stream is connected to
+ * @return string The URI of the endpoint
+ */
+PHP_METHOD(Channel, getTarget) {
+  wrapped_grpc_channel *channel =
+      (wrapped_grpc_channel *)zend_object_store_get_object(getThis() TSRMLS_CC);
+  RETURN_STRING(grpc_channel_get_target(channel->wrapped), 1);
+}
+
 /**
  * Close the channel
  */
@@ -208,7 +218,9 @@ PHP_METHOD(Channel, close) {
 
 static zend_function_entry channel_methods[] = {
     PHP_ME(Channel, __construct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_CTOR)
-    PHP_ME(Channel, close, NULL, ZEND_ACC_PUBLIC) PHP_FE_END};
+    PHP_ME(Channel, getTarget, NULL, ZEND_ACC_PUBLIC)
+    PHP_ME(Channel, close, NULL, ZEND_ACC_PUBLIC)
+    PHP_FE_END};
 
 void grpc_init_channel(TSRMLS_D) {
   zend_class_entry ce;
diff --git a/src/php/lib/Grpc/AbstractCall.php b/src/php/lib/Grpc/AbstractCall.php
index 5b28417a0df479d442fd4e91f81bbdc2b5b35547..35057224f8ca021b16eaba9b702a477aaea8eca3 100644
--- a/src/php/lib/Grpc/AbstractCall.php
+++ b/src/php/lib/Grpc/AbstractCall.php
@@ -67,6 +67,13 @@ abstract class AbstractCall {
     return $this->metadata;
   }
 
+  /**
+   * @return string The URI of the endpoint.
+   */
+  public function getPeer() {
+    return $this->call->getPeer();
+  }
+
   /**
    * Cancels the call
    */
diff --git a/src/php/lib/Grpc/BaseStub.php b/src/php/lib/Grpc/BaseStub.php
index 8c438e4bf92e6ac9a858a62f8de6d5c1e7b37d4d..a0c677908c7c4bc9714c8f5ffdc01401c1cf1d3b 100755
--- a/src/php/lib/Grpc/BaseStub.php
+++ b/src/php/lib/Grpc/BaseStub.php
@@ -67,6 +67,13 @@ class BaseStub {
     $this->channel = new Channel($hostname, $opts);
   }
 
+  /**
+   * @return string The URI of the endpoint.
+   */
+  public function getTarget() {
+    return $this->channel->getTarget();
+  }
+
   /**
    * Close the communication channel associated with this stub
    */
diff --git a/src/php/tests/generated_code/AbstractGeneratedCodeTest.php b/src/php/tests/generated_code/AbstractGeneratedCodeTest.php
index 6102aaf0a8b939041decab850cf7bf11b7ed59a6..8b7e67f57c25ffdbea4b1cec39e21ec6d1d33ed6 100644
--- a/src/php/tests/generated_code/AbstractGeneratedCodeTest.php
+++ b/src/php/tests/generated_code/AbstractGeneratedCodeTest.php
@@ -43,7 +43,9 @@ abstract class AbstractGeneratedCodeTest extends PHPUnit_Framework_TestCase {
     $div_arg = new math\DivArgs();
     $div_arg->setDividend(7);
     $div_arg->setDivisor(4);
-    list($response, $status) = self::$client->Div($div_arg)->wait();
+    $call = self::$client->Div($div_arg);
+    $this->assertTrue(is_string($call->getPeer()));
+    list($response, $status) = $call->wait();
     $this->assertSame(1, $response->getQuotient());
     $this->assertSame(3, $response->getRemainder());
     $this->assertSame(\Grpc\STATUS_OK, $status->code);
@@ -53,6 +55,7 @@ abstract class AbstractGeneratedCodeTest extends PHPUnit_Framework_TestCase {
     $fib_arg = new math\FibArgs();
     $fib_arg->setLimit(7);
     $call = self::$client->Fib($fib_arg);
+    $this->assertTrue(is_string($call->getPeer()));
     $result_array = iterator_to_array($call->responses());
     $extract_num = function($num){
       return $num->getNum();
@@ -72,6 +75,7 @@ abstract class AbstractGeneratedCodeTest extends PHPUnit_Framework_TestCase {
       }
     };
     $call = self::$client->Sum($num_iter());
+    $this->assertTrue(is_string($call->getPeer()));
     list($response, $status) = $call->wait();
     $this->assertSame(21, $response->getNum());
     $this->assertSame(\Grpc\STATUS_OK, $status->code);
@@ -79,6 +83,7 @@ abstract class AbstractGeneratedCodeTest extends PHPUnit_Framework_TestCase {
 
   public function testBidiStreaming() {
     $call = self::$client->DivMany();
+    $this->assertTrue(is_string($call->getPeer()));
     for ($i = 0; $i < 7; $i++) {
       $div_arg = new math\DivArgs();
       $div_arg->setDividend(2 * $i + 1);
diff --git a/src/php/tests/interop/interop_client.php b/src/php/tests/interop/interop_client.php
index 20415775574c3f1c77b68dccc3388ec30a7de71e..4bcf7df7f727885c52c34b436b3b27c481e87d4a 100755
--- a/src/php/tests/interop/interop_client.php
+++ b/src/php/tests/interop/interop_client.php
@@ -332,10 +332,11 @@ if (in_array($args['test_case'], array(
   $opts['update_metadata'] = $auth->getUpdateMetadataFunc();
 }
 
-$stub = new grpc\testing\TestServiceClient(
-    new Grpc\BaseStub(
-        $server_address,
-        $opts));
+$internal_stub = new Grpc\BaseStub($server_address, $opts);
+hardAssert($internal_stub->getTarget() == $server_address,
+           'Unexpected target URI value');
+
+$stub = new grpc\testing\TestServiceClient($internal_stub);
 
 echo "Connecting to $server_address\n";
 echo "Running test case $args[test_case]\n";
diff --git a/src/php/tests/unit_tests/CallTest.php b/src/php/tests/unit_tests/CallTest.php
index 77a2d86ce4cb5896a0812126d3f8df98f175d604..3d50da32512c9d23a7a823d6cf68f84ffa783a6e 100755
--- a/src/php/tests/unit_tests/CallTest.php
+++ b/src/php/tests/unit_tests/CallTest.php
@@ -79,4 +79,8 @@ class CallTest extends PHPUnit_Framework_TestCase{
     $result = $this->call->startBatch($batch);
     $this->assertTrue($result->send_metadata);
   }
+
+  public function testGetPeer() {
+    $this->assertTrue($this->call->getPeer() == 'localhost:' . self::$port);
+  }
 }
diff --git a/src/php/tests/unit_tests/EndToEndTest.php b/src/php/tests/unit_tests/EndToEndTest.php
index 2980dca4a750cc4c3b9b5d7f2cfb054d20b10400..9a1ab81acc401e6b3270a2a6bca7a1515ed2870a 100755
--- a/src/php/tests/unit_tests/EndToEndTest.php
+++ b/src/php/tests/unit_tests/EndToEndTest.php
@@ -34,8 +34,8 @@
 class EndToEndTest extends PHPUnit_Framework_TestCase{
   public function setUp() {
     $this->server = new Grpc\Server([]);
-    $port = $this->server->addHttp2Port('0.0.0.0:0');
-    $this->channel = new Grpc\Channel('localhost:' . $port, []);
+    $this->port = $this->server->addHttp2Port('0.0.0.0:0');
+    $this->channel = new Grpc\Channel('localhost:' . $this->port, []);
     $this->server->start();
   }
 
@@ -149,4 +149,8 @@ class EndToEndTest extends PHPUnit_Framework_TestCase{
     unset($call);
     unset($server_call);
   }
+
+  public function testGetTarget() {
+    $this->assertTrue($this->channel->getTarget() == 'localhost:' . $this->port);
+  }
 }