create firebase account and create new project
when create then install necessary firebase package in vscode
dart pub global activate flutterfire_cli
firebase_core: ^2.27.0 #install this
Then go terminal and paste this commend and make sire already login in vscode.
flutterfire configure
login gmail go and firebase projectr create and selected the project
then create two file one android/app --> google-services.json and two lib/ --> firebase_options.dart
then you go main.dart
replaces
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/material.dart';
import 'package:flutter_journey/firebase_options.dart'; // replace the path your project
void main() async {
WidgetsFlutterBinding.ensureInitialized();
await Firebase.initializeApp(
options: DefaultFirebaseOptions.currentPlatform,
);
runApp(const MyApp());
}