Google+ APIs will be shut down on March 7, 2019. This includes Google+ Sign-in and OAuth token requests with Google+ scopes. Learn more.

Google+ integrations for web and mobile apps will also cease to function March 7, 2019. Learn more.

This will be a progressive shutdown, with intermittent failures starting as early as January 28, 2019.

Sharing images and videos to Google+ from your Android app

The PlusShare.Builder class provides a setStream method that you can use to attach an image or video to a shared post.

Share an image or video

The following example demonstrates using a picker intent to choose an image or video from the gallery to share on Google+ when the user clicks a button in your app.

In your activity, configure your button's OnClickListener to launch the picker intent when clicked.:

private static final int REQ_SELECT_PHOTO = 1;
private static final int REQ_START_SHARE = 2;

protected void onCreate(Bundle savedInstanceState) {


    Button shareMediaButton = (Button) findViewById(;
    shareMediaButton.setOnClickListener(new android.view.View.OnClickListener() {
      public void onClick(View v) {
        Intent photoPicker = new Intent(Intent.ACTION_PICK);
        photoPicker.setType("video/*, image/*");
        startActivityForResult(photoPicker, REQ_SELECT_PHOTO);


protected void onActivityResult(int requestCode, int resultCode, Intent intent) {
  super.onActivityResult(requestCode, resultCode, intent);

  if(requestCode == REQ_SELECT_PHOTO) {
    if(resultCode == RESULT_OK) {
      Uri selectedImage = intent.getData();
      ContentResolver cr = this.getContentResolver();
      String mime = cr.getType(selectedImage);

      PlusShare.Builder share = new PlusShare.Builder(this);
      share.setText("hello everyone!");
      startActivityForResult(share.getIntent(), REQ_START_SHARE);

When you share media to Google+, you cannot also use the setContentUrl method. If you want to include a URL in the post with the media, you should append the URL to the prefilled text in the setText() method.

Next steps

Send feedback about...

Google+ Platform for Android
Google+ Platform for Android