Send Android Push Notifications Using Firebase Cloud Messaging | Android Studio (With Source Code)

Поделиться
HTML-код
  • Опубликовано: 31 июл 2024
  • Setup Firebase Cloud Messaging in Android Studio | Send Push Notifications using Firebase | Receive Firebase messages in Android using Java | Get device registration token | Show notification in foreground and background.
    **********************
    Free Document Proofreading
    Grammarly: grammarly.go2cloud.org/SH3YB
    Create a Professional Resume/CV:
    resume.io/?ref=4q4uda
    Top Web Hosting Providers:
    Hostinger: bit.ly/3reujGt
    iPage: bit.ly/3f335Qb
    Interserver: bit.ly/3LonwDj
    Namecheap : bit.ly/3dueuYP
    TurnKey Internet: bit.ly/3LyhdNp
    Virtual Private Network (VPN) Providers:
    NordVPN: bit.ly/3ScUwQY
    IPVanish: bit.ly/3qT1nU9
    Atlas VPN: bit.ly/3QV1ucn
    Website Security Platform
    Sucuri: bit.ly/3UfAxD0
    Amazone Articles:
    PC MSI Stealth: amzn.to/3DEsOsw
    PC Dell Latitude: amzn.to/3xB0rHT
    PC Dell Latitude: amzn.to/3SgtF6F
    PC ASUS TUF Gaming: amzn.to/3S1X6JV
    PC Dell Latitude: amzn.to/3f3aLBI
    PC ASUS VivoBook: amzn.to/3QR5oCV
    PC Acer Swift 3: amzn.to/3RZbK4w
    Samsung Galaxy Z Fold: amzn.to/3BSXiFR
    Samsung Galaxy S10+: amzn.to/3SkT5QJ
    SAMSUNG Galaxy S21: amzn.to/3BpPhqt
    SAMSUNG Galaxy Z Flip: amzn.to/3DBPr0x
    SAMSUNG Galaxy S9+: amzn.to/3RYJL50
    **********************
    Source code link: bit.ly/3uV5H8B
    **********************
    Video Content
    (00:00) Create Android Project
    (00:45) Setup Firebase Cloud Messaging
    (03:03) Get Device Registration Token
    (07:54) Send Firebase Push Notifications
    (09:59) Receive Firebase Messages
    (13:43) Create Android Notifications .
    ***********************************
    🔥 Complete Udemy Courses :
    Build E-commerce Web Application using ASP.NET Core : www.udemy.com/course/aspnet-c...
    Build E-commerce Web API using ASP.NET Core : www.udemy.com/course/build-as...
    Build E-commerce Web Application using React JS : www.udemy.com/course/build-co...
    ⬇️ Free Document Proofreading ⬇️
    ► Grammarly : grammarly.go2cloud.org/SH3YB

Комментарии • 72

  • @aamirhoda7363
    @aamirhoda7363 2 года назад +1

    Sweet & Simple Tutorial for understanding Notifications. Precise to the point. 🤩

  • @techsangrah3982
    @techsangrah3982 Год назад +1

    very helpful for me. i have see many other videos but i can't understand
    thank you for this simple tutorial

  • @supunvithana7169
    @supunvithana7169 Год назад

    Love this tutorial. Very simple and clear

  • @minhthanhnguyen8936
    @minhthanhnguyen8936 2 года назад

    Thank you very much. Very useful, it resolve my problem which took me 4 days to find out

  • @dlentertainment9917
    @dlentertainment9917 Год назад

    What an amazing video. I don't usually comment but you deserve it :D

  • @randomweins4894
    @randomweins4894 2 года назад +1

    clear and specific tutorial, very Good. keep going on this... I am sure you will get much support...

  • @joserubensferreira7244
    @joserubensferreira7244 Год назад

    Top, excellent tutorial, simple and objective. Thank you!

  • @sureshveerasamy1422
    @sureshveerasamy1422 Год назад

    Very Good Learning....Thanks a Lot for your Lesson.👌

  • @daahqaadchannel5399
    @daahqaadchannel5399 2 года назад

    Thanks For the best Explanation 👌

  • @priscillavannyamelia8736
    @priscillavannyamelia8736 Год назад

    simple and easy to understand tutorial

  • @rafaelkontein2683
    @rafaelkontein2683 2 года назад +2

    Sou Brasileiro, Parabens pelo video!!!!!!!!! muito bom !!

  • @chucklesome1275
    @chucklesome1275 Год назад +1

    Toast Display: In your sendNotification() method, you're attempting to display a Toast message from a background thread by using a Handler to post the operation on the main looper. However, the FirebaseMessagingService already runs on the main thread, so there's no need for the Handler. You can directly display the Toast without the Handler'

  • @jaxxrr
    @jaxxrr 5 месяцев назад +1

    did everything got the token but when I try to test it no message arrives.. not even in background..

  • @MrJorgeUriarte
    @MrJorgeUriarte Год назад

    Great Tutorial!.. Thanks for sharing

  • @naseerjamal1934
    @naseerjamal1934 Год назад

    Good job bro. It helped me a lot. the easiest of all.

  • @user-ik1yr6ih2j
    @user-ik1yr6ih2j 2 года назад

    Thank you!!! It was very useful!!

  • @yusufmustari
    @yusufmustari 2 года назад

    Thank you sir!!! It was very useful!!

  • @oleksandr3275
    @oleksandr3275 Год назад

    Thank you, it works exactly as in video👍

  • @Kaito-rt4ux
    @Kaito-rt4ux 9 месяцев назад +1

    How to implement a fixed notification message that will appear in both foreground and background that only triggers by conditional statements?

  • @kristopherortiz1049
    @kristopherortiz1049 2 года назад

    greetings, I hope all is well. I generated a debug apk and noticed it isnt receiving any notifications. i added the sha1 key to it.
    it only works when i install the app directly to my device.
    do i need to do any further steps so this works?
    thank you in advance!

  • @kamil2k111
    @kamil2k111 Год назад

    Thanks a Lot for your Lesson

  • @manjilapp9578
    @manjilapp9578 2 года назад

    Awesome tutorial brother...

  • @abhisheksinghal4470
    @abhisheksinghal4470 2 года назад

    Nice Explanation !!

  • @zeris3134
    @zeris3134 Год назад

    thank you for the video question is it okay not to display the token on the main activity and just when clicking the notification it just opens the main activity?

  • @ElectroCoderEC
    @ElectroCoderEC Год назад

    Niceeeeeeeeeeeee amazing so simple and fast. That's All :)

  • @johanromuald6166
    @johanromuald6166 Год назад

    Thank you very much. Google should learn from you, how to create tutorial and documentation. Further if I have the token id, can I develop my own pc based application to send notification to phones via Firebase cloud messaging without suing cloud console. Thanks

  • @srgIt
    @srgIt Год назад

    best example for beginner and way of explain is very simple point to point, I am trying push notification first time and this tutorial is solve my complete problem

  • @dineshchamara3550
    @dineshchamara3550 Год назад

    Tnx very simple 😘😘😘😘😘😘

  • @user-ow1he8qm2h
    @user-ow1he8qm2h Год назад

    Cool tutorial!

  • @JafarSiddikee
    @JafarSiddikee 2 года назад

    Hi. Very useful tutorial. I am facing issue with android 12. When app closed its not getting push notification. But upto android 11 its working. Can you please suggest about android 12 related issue

  • @vincentluo3292
    @vincentluo3292 Год назад

    I have tried many time , I success got the token in virtual device phone ,but virtual device phone nerver receive Topic message from FCM consol.....Help ....

  • @kshorts7726
    @kshorts7726 9 месяцев назад

    Best explanation

  • @neiltonna8737
    @neiltonna8737 Год назад

    King, thank you !!

  • @SkySea1993
    @SkySea1993 Год назад

    Thank you 💗

  • @aminshafiq2534
    @aminshafiq2534 Год назад +1

    sorry how did he generate that toast message code at 13:12

  • @sederafanomezana7805
    @sederafanomezana7805 2 года назад

    Thank you!

  • @TheChronosTyle
    @TheChronosTyle Год назад

    will the background notification still work even if the app just terminated?

  • @AmazingRealityKH
    @AmazingRealityKH Год назад

    send notification InApp not working? can you show me?

  • @starttoday1522
    @starttoday1522 Год назад

    How to send this notification to already installed device ( using pakage name)

  • @evangelistar
    @evangelistar 4 месяца назад

    Great video

  • @m.arslan-mas6775
    @m.arslan-mas6775 2 года назад

    not working on android version 10

  • @devendragiriaparanathi9207
    @devendragiriaparanathi9207 2 года назад

    How to add accept reject button in notification

  • @surgicalsystemsg4277
    @surgicalsystemsg4277 2 года назад

    Hey man, awesome tutorial. Could you please guide me on how to get the device token while using webview

  • @adar3997
    @adar3997 2 года назад +2

    There is a way to do it automatically (without clicking manually on the button in the firebase website)?

    • @Kaito-rt4ux
      @Kaito-rt4ux 8 месяцев назад

      Im waiting for this question to be answered please before our project defense

  • @rektgaming69
    @rektgaming69 2 года назад

    Next video on Google authentication :)

  • @pablotandil7000
    @pablotandil7000 2 года назад

    Thanks very much, from Argentina! Excelente video!

  • @user-jk1uh7qe3x
    @user-jk1uh7qe3x Год назад

    I didn't receive the push notification
    is it have any alternative solutions??????

  • @sanjibbarma9542
    @sanjibbarma9542 2 года назад

    not working on real device what should i do??

  • @visibleuser8973
    @visibleuser8973 Год назад

    thnx bro

  • @kamal7304
    @kamal7304 Год назад +1

    Hi, can you help me please

  • @vijayvelayutham7135
    @vijayvelayutham7135 2 года назад +4

    Hi, your tutorial is simple and neat. First time i tried with a project and i got to a point that i could generate the FMC token but i couldnt have the messages been pushed to the emulator. Created a new project and retried but this time, its stopped at ":E/FirebaseMessaging: Topic sync or token retrieval failed on hard failure exceptions: java.util.concurrent.ExecutionException: java.io.IOException: AUTHENTICATION_FAILED. Won't retry the operation." I couldnt even get the FCM token, Everytime i create a new FB project in FB console. Has anyone experienced the same? I use Pixel 5 API 22, 32, 30

  • @blueeyes9691
    @blueeyes9691 10 месяцев назад

    Thanks youuuuu

  • @kevovoke
    @kevovoke 2 года назад

    How do I automate this

  • @starttoday1522
    @starttoday1522 Год назад

    Please upload video i want to send notification for all users who are all installed my application using pakage name😢😢😢

  • @fatonpodrimqaku1793
    @fatonpodrimqaku1793 Год назад

    Love You Brroder

  • @starttoday1522
    @starttoday1522 Год назад

    Do you know how to send notification on installed device?😢 Sir

  • @creativesolutionbd
    @creativesolutionbd Год назад

    Download link not working

  • @prowsebenedict2015
    @prowsebenedict2015 2 года назад

    Is there a way to send notifications to multiple devices but not only one device? Thanks

    • @starttoday1522
      @starttoday1522 Год назад

      Do you know how to send notification on installed device?😢 Sir

  • @thinq5339
    @thinq5339 Год назад

    not received on device

  • @gautamshenoy6170
    @gautamshenoy6170 2 года назад

    Whats the point ?

  • @starttoday1522
    @starttoday1522 Год назад

    I am waiting for your reply sir
    😢

  • @bigstrongrobot1330
    @bigstrongrobot1330 2 года назад

    13:09 what have you done here please !! How did you display this

    • @BoostMyTool
      @BoostMyTool  2 года назад +1

      you cannot display the toast from the service. the service should inform the activity to display a toast

    • @aamirhoda7363
      @aamirhoda7363 2 года назад

      Service would probably be running on a worker thread (other than the Main UI thread), thus you can't interact with anything on the main thread.
      So in order to interact with the main thread on the background thread, one can use a "Handler" with "Looper.getMainLooper()" as parameter, to pass events (in this case, a mere toast) to the main thread.

  • @josephd.1447
    @josephd.1447 2 года назад

    13:07 how to display a toast ???

    • @josephd.1447
      @josephd.1447 2 года назад

      Reply ASAP Please

    • @BoostMyTool
      @BoostMyTool  2 года назад

      Toast.makeText(this, "your message here", Toast.LENGTH_LONG).show();