Social Sharing

Share text, images and url with various apps in your device

Every app requires sharing in one way or another. Social Sharing plugin allows you to use the native sharing window of your mobile device.

  • Works on Android, version 2.3.3 and higher (probably 2.2 as well).

  • Works on iOS6 and up.

  • Works on Windows Phone 8 since v4.0 of this plugin (maybe even WP7, but I have no such test device).

  • Share text, a link, a images (or other files like pdf or ics). Subject is also supported, when the receiving app supports it.

  • Supports sharing files from the internet, the local filesystem, or from the www folder.

  • You can skip the sharing dialog and directly share to Twitter, Facebook, or other apps.

Install the plugin

$ ionic cordova plugin add cordova-plugin-x-socialsharing
$ npm install @ionic-native/social-sharing

and import the plugin in your pages

import { SocialSharing } from '@ionic-native/social-sharing/ngx';

constructor(private socialSharing: SocialSharing) { }

In Capacitor Full App, this plugin's implementation can be found at src/app/pages/pro/social-share

Sharing with Whatsapp

You can share text, images or url. If any data is missing, use null in its place.

Sharing with Instagram

Sharing with Facebook

Text may be ignored by Facebook, as it often does not allow preset text to be filled in Facebook posts or shares.

Sharing with Twitter

Sharing with Email

Check if email sharing is possible

And then share with email

Last updated

Was this helpful?