- 3 способа установить APK-файл на Android
- Подготовка ОС Android
- Простой способ
- Способ средней сложности
- Продвинутый способ
- How to Install APK on Android
- Have an Android app not on Google Play? Install it from its APK
- What to Know
- Allow Unknown Apps on Android
- Install an Android File Manager
- Download the APK Installer From Your Android
- Transfer the APK Installer via USB
- Advanced: Run APK Installer With Minimal ADB and Fastboot
- What Is an APK?
- Why Use an APK?
- Finding APK Installers
- Download and Install APK Programmatically
- Conclusion
- Get Solution Code
- Keep in touch
3 способа установить APK-файл на Android
APK (Android Package Kit) – это тип файла, который содержит в себе приложение для Android. Это очень похоже на установочные программы для Windows или Mac (.exe или .pkg). Все, что нужно сделать с APK, — это открыть его. Процесс установки произойдет автоматически.
Если вы когда-нибудь устанавливали приложение из Google Play, то уже имели опыт работы с APK, не осознавая этого. Когда вы нажимаете зеленую кнопку «Установить», Google Play автоматизирует процесс переноса APK на смартфон и после скачивания запускает процесс установки.
А что делать, если приложение, которое вы хотите установить, недоступно в Google Play? В этом случае нужно взять дело в свои руки. Существует множество каталогов APK-файлов, на которых можно найти нужное приложение. Двумя наиболее популярными и надежными являются APK Pure и APK Mirror. Ниже будут описаны 3 метода установки в различных ситуациях.
Подготовка ОС Android
Смартфон автоматически распознает любое приложение, поступившее не из Google Play, как «неизвестное приложение». Поэтому в настройках нужно разрешить установку из неизвестных источников.
Сделать это достаточно просто. Перейдите в раздел настроек. Выберите «Безопасность» (или «Блокировка экрана и безопасность»). Найдите пункт «Администрирование устройства» и включите установку из неизвестных источников.
После разрешения установки приложений из неизвестных источников понадобится найти APK-файл в смартфоне. Обычно на Android уже есть стандартный диспетчер файлов. Если же его нет, зайдите в Google Play и поищите приложения по ключевому словау «Диспетчер файлов». Появится много вариантов. Выберите любой из них или просто скачайте самый популярный — Cx File Explorer.
Простой способ
Самый простой способ установить APK на Android – это скачать его с помощью мобильного браузера. Найдите сайт, предлагающий приложение для Android. На нем вы увидите ссылку для скачивания. Может появиться всплывающее окно с вопросом, хотите ли вы разрешить браузеру сохранять файлы в хранилище смартфона. Ответьте согласием. Вы также увидите предупреждение о том, что «этот тип файла может повредить ваше устройство». Просто нажимайте «ОК» и продолжайте.
Если браузер смартфона не позволяет открыть файл после скачивания, откройте файловый менеджер и найдите папку Downloads. Нажмите на скачанный файл и разрешите приложению выполнить необходимые действия, которые оно запрашивает. Затем в нижней части окна нажмите кнопку «Установить».
Вы увидите уведомление о том, что приложение установлено. После этого оно должно появиться в списке программ. Если же что-то не получилось, попробуйте воспользоваться другими способами.
Способ средней сложности
Если у вас нет доступа в интернет или по какой-то другой причине вы не можете использовать браузер, есть возможность установить приложение с настольного компьютера.
С помощью браузера на компьютер скачайте APK. Затем подключите смартфон к компьютеру и скопируйте на него файл. Если раньше вы никогда не делали этого, нужно будет включить отладку по USB.
Для этого выберите «Настройки», прокрутите вниз до пункта «Об устройстве» и семь раз нажмите «Номер сборки». Это откроет вам скрытое меню разработчика. Вернитесь в «Настройки», выберите «Параметры разработчика» и нажмите «Отладка по USB». Установите флажок напротив пункта «Отладка по USB».
Теперь вы можете подключить смартфон к компьютеру при помощи USB-кабеля. Устройство должно определиться так же, как карта памяти или флешка. Переместите файл, скачанный с сайта, на смартфон. Вот что нужно сделать для этого:
- Найдите нужный файл на компьютере.
- Кликните по нему правой кнопкой мышки и выберите пункт «Копировать».
- Найдите на ПК смартфон, который отображается как съемный диск.
- Откройте его и найдите папку /sdcard/download.
- Скопируйте APK в эту папку.
После завершения копирования используйте менеджер файлов на смартфоне, чтобы найти его и запустить.
Если у вас нет USB-кабеля, можно установить WiFi FTP-Server из Google Play, а затем использовать FTP-клиент на компьютере для переноса файла. Но это более сложный вариант, USB-кабель обычно легче найти.
Продвинутый способ
Если по какой-либо причине установщик APK не запускается, когда вы нажимаете на него на смартфоне, можно прибегнуть к экстренному решению. В данном случае предполагается запуск APK Installer с Minimal ADB и Fastboot. Вы можете установить приложение на Android-устройство с компьютера, используя простой инструмент под названием Minimal ADB и Fastboot.
Вам необходимо выполнить действия, описанные в предыдущем разделе, чтобы подключить смартфон к ПК. Затем скачайте и установите на компьютер последнюю версию Minimal ADB и Fastboot. Запустите инструмент, и откройте командную строку. После синхронизации смартфона с ПК введите команду:
Если программа обнаружит смартфон, то вы увидите его идентификатор в списке подключенных устройств.
Теперь с помощью проводника Windows перейдите в папку Minimal ADB и Fasbtoot (обычно это C:\Program Files (x86)\Minimal ADB and Fastboot). Вставьте файл APK в эту папку. Можно переименовать файл, присвоив ему короткое название. Так его будет легче вручную вводить в командную строку.
Вернувшись в то же командное окно, которое вы открывали ранее, введите команду:
Вместо name-of-file впишите название файла, которое присвоили ему во время переименования. Подождите пару секунд. Готово!
Источник
How to Install APK on Android
Have an Android app not on Google Play? Install it from its APK
What to Know
- Allow Chrome to install unknown apps by going to Settings >Apps >Menu >Special access >Install unknown apps.
- Install a file manager (such as Cx File Explorer or File Manager) so that you can find the APK file after you download it to your phone.
- Download an APK file and open it to install it. Alternatively, transfer the APK Installer from your computer using USB.
If you want to use an app from outside of the Google Play Store, you can install the app’s APK file. This article explains how to install APKs on Android 7 or later.
Allow Unknown Apps on Android
Before you can download APK files using Chrome or any other browser, you must first allow unknown apps:
Go to your device settings and tap Apps & Notifications (or Apps in older versions of Android).
Tap the three dots in the upper-right corner.
Tap Special access.
Tap Install unknown apps.
Tap Chrome (or whichever web browser you use)
Move Allow from this source to the On position.
Install an Android File Manager
Now that you’ve configured your phone to let you install unknown apps, you’ll need a way to find the application file (APK file) on your phone so that you can run it.
Android phones typically come with a file manager app you can use, but if you don’t have one, search for one on Google Play. Some of the best options include Cx File Explorer and File Manager.
Download the APK Installer From Your Android
The easiest way to install an APK file on your Android is to download the file using the default browser, Chrome.
Find a website offering the Android app and tap the link to download the APK file. Accept any pop-ups, including “This type of file can harm your device.”
Only download APK files from reputable sources. A quick Google search can often let you know if an app (or company that makes the app) has a questionable reputation.
If your phone’s web browser doesn’t give you the option to open the file after downloading, open your file explorer app, go to the Downloads folder on your device, then tap the APK file.
Allow the app any required permissions it asks for. Then, at the bottom of the installer window, tap Install.
Now you’ll see the app available in your list of installed apps.
Transfer the APK Installer via USB
If you don’t have internet access on your phone, or for any other reason you can’t use a browser to download the file, you can still install apps from your computer. Using your computer web browser, download the APK file just like described above. Once it’s downloaded, connect to your Android phone and transfer the file.
If you’ve never connected your Android to your computer, enable USB Debugging. You can then plug your phone into your computer with a USB cable, and it’ll mount the phone like it would a memory stick.
Once your phone is connected to your computer, it shows up as another drive in your computer’s File Explorer. Move the APK file you downloaded from the app website to the /sdcard/download folder on your phone.
Once the file is transferred, use the file explorer app on your phone as described in the previous section to tap the APK file and install the app.
If you don’t have a USB cable, another solution is to install WiFi FTP Server from Google Play. Then, use an FTP client on your computer (like FileZilla) to transfer the APK file from your computer to the /sdcard/download folder on your phone. However, this is an advanced option and requires an understanding of how to use FTP files.
Advanced: Run APK Installer With Minimal ADB and Fastboot
If the APK installer isn’t running when you tap it, there’s an advanced solution that might work. You can install the APK file on your Android from your computer using a tool called Minimal ADB and Fastboot.
Connect your phone via USB and enable USB Debugging.
Download and install the latest version of Minimal ADB and Fastboot on your computer.
Run the tool, and a command window opens. With your phone connected to your computer with the USB cable, type the command adb devices.
If the tool detects your phone, an ID for the device appears under List of devices attached. Now you’re ready to transfer the APK file.
Using Windows File Explorer, find the downloaded APK file on your computer.
Right-click the file and select Copy.
Using Windows File Explorer, navigate to the Minimal ADB and Fasbtoot folder (typically c:\Program Files (x86)\Minimal ADB and Fastboot\).
Paste the APK file into that folder.
Rename the APK file to something short so that it’s easy to type as a command.
Back in the same command window you had open before, type the command adb install app name (replace with the name of your APK file).
When you see the word Success, the app is installed on your phone.
What Is an APK?
An APK (Android Package Kit) is a type of file that installs an application for Android. It’s just like an executable (EXE) file for Windows or a package installer (PKG) for Mac.
If you’ve ever installed an Android application from the Google Play store, then you’ve used an APK file without realizing it. When you tap the Install button, Google Play automates the process of transferring the APK file to your phone and running it for you.
Why Use an APK?
If the Android app you want to install isn’t available on Google Play, you can download the APK file from the web and install it manually.
Finding APK Installers
There are many websites where you can find non-Google Play apps to install. Three of the most popular are APK Pure, Reddit’s APK Directory, and APK Mirror.
Источник
Download and Install APK Programmatically
Hello guys, as per title in this post I ‘ll tell you how to download the app using a download manager and install it programmatically. For doing that will create a sample app, for more detail you can watch feature video as well. So let’s get started
Download and Install APK (Demo APP)
Create a new Project
Open Android Studio and create a new android project with any default template. Once project sync is finished, open app-level build.gradle. In this android example we’ll use Snackbar for that we have to add material io dependencies. so let’s do that
Add uses permission
I’m going to download the APK file so we need storage permission and Internet permission. Once the app is download successfully than we will install it programmatically. For doing that we must need REQUEST_INSTALL_PACKAGES permission. Let’ s all needed permission in android manifest.
Create a file provider
You guys, already aware that in android N or above we have to write a file provider. Let’s create a resource file inside res=>xml=> named is file_provider_paths.xml
Now declare the file provider inside the manifest
Add some value inside strings.xml file
Create a download controller
Let’s create a file named is DownloadController, It’s controller is responsible to download file install it. This DownloadController we are using download manager for downloading APK.
Open the main activity layout file add one button
Create an extension file
For better coding practice, removing boilerplate code. We’ll write few extensions for AppCompatActivity and Snackbar. let’s create extension file and paste below code
Open main activity file
Let’s open the file and paste the below code. In this activity, we are checking storage permission first. If permission is granted than calling download function otherwise requesting for storage permission.
Conclusion
All done, In this tutorial, we have learned how to download APK and Install it programmatically. I hope it’s helpful for you, Help me by sharing this post with all your friends.
Get Solution Code
Keep in touch
If you have any queries, feel free to ask them in the comment section below. 🙂
Источник