# How to import powershell module from local file (intelNetCmdlet.psd1)

**URL:** <https://forum.ansible.com/t/how-to-import-powershell-module-from-local-file-intelnetcmdlet-psd1/3135>\
**Category:** Get Help\
**Tags:** powershell, windows, collections\
**Created:** [January 3, 2024, 12:16pm UTC](https://forum.ansible.com/t/how-to-import-powershell-module-from-local-file-intelnetcmdlet-psd1/3135 "2024-01-03T12:16:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![car](https://avatars.discourse-cdn.com/v4/letter/c/c2a13f/32.png) [@car](https://forum.ansible.com/u/car)\
**Post date:** [January 3, 2024, 12:16pm UTC](https://forum.ansible.com/t/how-to-import-powershell-module-from-local-file-intelnetcmdlet-psd1/3135/1 "2024-01-03T12:16:13Z")

</div>

Hi all,

Have any of You tried to import a powershell module from local file (intelNetCmdlet.psd1) and then run cmdlets

I can make the module work outside Ansible with import-module -path “C:\somepath.psd1” on windows.

Thank you.

/Car

---

<div class="post-metadata">

**Author:** ![ptn](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/ptn/32/481_2.png) [@ptn](https://forum.ansible.com/u/ptn)\
**Post date:** [January 3, 2024, 5:36pm UTC](https://forum.ansible.com/t/how-to-import-powershell-module-from-local-file-intelnetcmdlet-psd1/3135/2 "2024-01-03T17:36:05Z")

</div>

Hi,

[This module](https://docs.ansible.com/ansible/latest/collections/community/windows/win_psmodule_module.html#win-psmodule-module) seems to be of use to install PS modules, but I can’t tell for sure it can’t be used to import those as well.

If not, you could still use [ansible.windows.win\_powershell](https://docs.ansible.com/ansible/latest/collections/ansible/windows/win_powershell_module.html#ansible-collections-ansible-windows-win-powershell-module) to import your modules through `script` parameter, running your `ipmo` command from there.

---

<div class="post-metadata">

**Author:** ![jborean](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/jborean/32/1525_2.png) [@jborean](https://forum.ansible.com/u/jborean)\
**Post date:** [January 3, 2024, 9:17pm UTC](https://forum.ansible.com/t/how-to-import-powershell-module-from-local-file-intelnetcmdlet-psd1/3135/3 "2024-01-03T21:17:06Z")

</div>

Either you have it installed as any other normal module on the target Windows host so you can do `Import-Module intelNetCmdlet` or you manually import it with the path.
